/*! For license information please see main-ng.js.LICENSE.txt */
!function() {
var e = {
26981: function(e, t, n) {
"use strict";
n(11983);
var i, o = (i = n(40115)) && i.__esModule ? i : {
default: i
};
o.default._babelPolyfill && "undefined" != typeof console && console.warn && console.warn("@babel/polyfill is loaded more than once on this page. This is probably not desirable/intended and may have consequences if different versions of the polyfills are applied sequentially. If you do need to load the polyfill more than once, use @babel/polyfill/noConflict instead to bypass the warning."),
o.default._babelPolyfill = !0
},
11983: function(e, t, n) {
"use strict";
n(16266),
n(10990),
n(70911),
n(14160),
n(6197),
n(96728),
n(54039),
n(93568),
n(78051),
n(38250),
n(15434),
n(54952),
n(96337),
n(35666)
},
17970: function(e, t, n) {
"use strict";
n.r(t),
n.d(t, {
init: function() {
return a
},
toggle: function() {
return s
},
show: function() {
return l
},
hide: function() {
return c
}
});
var i = n(19755)
, o = !1
, r = !1
, a = function() {
i("#loader".length < 1) && i("body").append('\n
\n '),
i(document).on("keyup", (function(e) {
27 === e.keyCode && c()
}
)),
r = !0
}
, s = function(e) {
r || a(),
(o = !o) ? l() : c(),
"function" == typeof e && (-1 != navigator.userAgent.indexOf("Safari") && -1 == navigator.userAgent.indexOf("Chrome") ? setTimeout((function() {
e()
}
), 500) : e())
}
, l = function() {
o = !0,
i("#loader").show()
}
, c = function() {
o = !1,
i("#loader").hide()
}
},
54648: function(e, t, n) {
"use strict";
n.r(t),
n.d(t, {
emailRegexp: function() {
return i
},
phone: function() {
return o
},
companyCode: function() {
return r
},
membershipNumber: function() {
return a
},
alphanumeric: function() {
return s
},
noHtmlTags: function() {
return l
}
});
var i = /^[-0-9a-zA-Z.+_]+@[-0-9a-zA-Z.+_]+\.[a-zA-Z]{2,12}$/
, o = Object.freeze({
strict: /^(?![0\D]+$)[\s\d()\\-]{1,20}$/,
loose: /^\+?[0-9 \-\(\)]+$/
})
, r = /^d\d+$/i
, a = /^30812(?!(0|1|2))[0-9]{9}$/
, s = Object.freeze({
noSpecialCharacters: /^[A-Za-z¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþÿ0-9-\s]*$/,
noSpecialCharactersExceptPeriod: /^[A-Za-z¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþÿ0-9-\.\s]*$/,
streetAddress: /^[[A-Za-z¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþÿ0-9-\.,\s/]*$/,
password: /^[A-Za-z0-9@#%\*]*$/
})
, l = /^[^<>]*$/
},
52071: function(e, t, n) {
var i = n(19755);
!function() {
"use strict";
i(".skip-to-content").click((function() {
var e = "#" + this.href.split("#")[1];
i(e).attr("tabindex", -1).on("blur focusout", (function() {
i(this).removeAttr("tabindex")
}
)).focus()
}
))
}()
},
69219: function(e, t, n) {
var i, o, r, a, s, l, c, u = n(19755);
function d(e) {
return d = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
return typeof e
}
: function(e) {
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e
}
,
d(e)
}
!function(e) {
function t(t, n) {
var i, o = this, r = window.navigator, a = r.userAgent.toLowerCase();
o.uid = e.rsModules.uid++,
o.ns = ".rs" + o.uid;
var s, l = document.createElement("div").style, c = ["webkit", "Moz", "ms", "O"], u = "", d = 0;
for (i = 0; i < c.length; i++) {
var f = c[i];
!u && f + "Transform"in l && (u = f),
f = f.toLowerCase(),
window.requestAnimationFrame || (window.requestAnimationFrame = window[f + "RequestAnimationFrame"],
window.cancelAnimationFrame = window[f + "CancelAnimationFrame"] || window[f + "CancelRequestAnimationFrame"])
}
window.requestAnimationFrame || (window.requestAnimationFrame = function(e, t) {
var n = (new Date).getTime()
, i = Math.max(0, 16 - (n - d))
, o = window.setTimeout((function() {
e(n + i)
}
), i);
return d = n + i,
o
}
),
window.cancelAnimationFrame || (window.cancelAnimationFrame = function(e) {
clearTimeout(e)
}
),
o.isIPAD = a.match(/(ipad)/),
o.isIOS = o.isIPAD || a.match(/(iphone|ipod)/),
i = function(e) {
return {
browser: (e = /(chrome)[ \/]([\w.]+)/.exec(e) || /(webkit)[ \/]([\w.]+)/.exec(e) || /(opera)(?:.*version|)[ \/]([\w.]+)/.exec(e) || /(msie) ([\w.]+)/.exec(e) || 0 > e.indexOf("compatible") && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(e) || [])[1] || "",
version: e[2] || "0"
}
}(a),
c = {},
i.browser && (c[i.browser] = !0,
c.version = i.version),
c.chrome && (c.webkit = !0),
o._browser = c,
o.isAndroid = -1 < a.indexOf("android"),
o.slider = e(t),
o.ev = e(o),
o._doc = e(document),
o.st = e.extend({}, e.fn.royalSlider.defaults, n),
o._currAnimSpeed = o.st.transitionSpeed,
o._minPosOffset = 0,
!o.st.allowCSS3 || c.webkit && !o.st.allowCSS3OnWebkit || (i = u + (u ? "T" : "t"),
o._useCSS3Transitions = i + "ransform"in l && i + "ransition"in l,
o._useCSS3Transitions && (o._use3dTransform = u + (u ? "P" : "p") + "erspective"in l)),
u = u.toLowerCase(),
o._vendorPref = "-" + u + "-",
o._slidesHorizontal = "vertical" !== o.st.slidesOrientation,
o._reorderProp = o._slidesHorizontal ? "left" : "top",
o._sizeProp = o._slidesHorizontal ? "width" : "height",
o._prevNavItemId = -1,
o._isMove = "fade" !== o.st.transitionType,
o._isMove || (o.st.sliderDrag = !1,
o._fadeZIndex = 10),
o._opacityCSS = "z-index:0; display:none; opacity:0;",
o._newSlideId = 0,
o._sPosition = 0,
o._nextSlidePos = 0,
e.each(e.rsModules, (function(e, t) {
"uid" !== e && t.call(o)
}
)),
o.slides = [],
o._idCount = 0,
(o.st.slides ? e(o.st.slides) : o.slider.children().detach()).each((function() {
o._parseNode(this, !0)
}
)),
o.st.randomizeSlides && o.slides.sort((function() {
return .5 - Math.random()
}
)),
o.numSlides = o.slides.length,
o._refreshNumPreloadImages(),
o.st.startSlideId ? o.st.startSlideId > o.numSlides - 1 && (o.st.startSlideId = o.numSlides - 1) : o.st.startSlideId = 0,
o._newSlideId = o.staticSlideId = o.currSlideId = o._realId = o.st.startSlideId,
o.currSlide = o.slides[o.currSlideId],
o._accelerationPos = 0,
o.pointerMultitouch = !1,
o.slider.addClass((o._slidesHorizontal ? "rsHor" : "rsVer") + (o._isMove ? "" : " rsFade")),
l = '',
o.slidesSpacing = o.st.slidesSpacing,
o._slideSize = (o._slidesHorizontal ? o.slider.width() : o.slider.height()) + o.st.slidesSpacing,
o._preload = 0 < o._numPreloadImages,
1 >= o.numSlides && (o._loop = !1),
o._loopHelpers = o._loop && o._isMove ? 2 === o.numSlides ? 1 : 2 : 0,
o._maxImages = 6 > o.numSlides ? o.numSlides : 6,
o._currBlockIndex = 0,
o._idOffset = 0,
o.slidesJQ = [];
for (i = 0; i < o.numSlides; i++)
o.slidesJQ.push(e(''));
o._sliderOverflow = l = e(l + "
"),
u = function(e, t, n, i, r) {
o._downEvent = e + t,
o._moveEvent = e + n,
o._upEvent = e + i,
r && (o._cancelEvent = e + r)
}
,
i = r.pointerEnabled,
o.pointerEnabled = i || r.msPointerEnabled,
o.pointerEnabled ? (o.hasTouch = !1,
o._lastItemFriction = .2,
o.pointerMultitouch = 1 < r[(i ? "m" : "msM") + "axTouchPoints"],
i ? u("pointer", "down", "move", "up", "cancel") : u("MSPointer", "Down", "Move", "Up", "Cancel")) : (o.isIOS ? o._downEvent = o._moveEvent = o._upEvent = o._cancelEvent = "" : u("mouse", "down", "move", "up"),
"ontouchstart"in window || "createTouch"in document ? (o.hasTouch = !0,
o._downEvent += " touchstart",
o._moveEvent += " touchmove",
o._upEvent += " touchend",
o._cancelEvent += " touchcancel",
o._lastItemFriction = .5,
o.st.sliderTouch && (o._hasDrag = !0)) : (o.hasTouch = !1,
o._lastItemFriction = .2)),
o.st.sliderDrag && (o._hasDrag = !0,
c.msie || c.opera ? o._grabCursor = o._grabbingCursor = "move" : c.mozilla ? (o._grabCursor = "-moz-grab",
o._grabbingCursor = "-moz-grabbing") : c.webkit && -1 != r.platform.indexOf("Mac") && (o._grabCursor = "-webkit-grab",
o._grabbingCursor = "-webkit-grabbing"),
o._setGrabCursor()),
o.slider.html(l),
o._controlsContainer = o.st.controlsInside ? o._sliderOverflow : o.slider,
o._slidesContainer = o._sliderOverflow.children(".rsContainer"),
o.pointerEnabled && o._slidesContainer.css((i ? "" : "-ms-") + "touch-action", o._slidesHorizontal ? "pan-y" : "pan-x"),
o._preloader = e('
'),
r = o._slidesContainer.children(".rsSlide"),
o._currHolder = o.slidesJQ[o.currSlideId],
o._selectedSlideHolder = 0,
o._eventCallbacks = {
dragStart: function(e) {
o._onDragStart(e)
},
dragStartThumb: function(e) {
o._onDragStart(e, !0)
},
touchmoveFix: function() {}
},
o._useCSS3Transitions ? (o._TP = "transition-property",
o._TD = "transition-duration",
o._TTF = "transition-timing-function",
o._yProp = o._xProp = o._vendorPref + "transform",
o._use3dTransform ? (c.webkit && !c.chrome && o.slider.addClass("rsWebkit3d"),
o._tPref1 = "translate3d(",
o._tPref2 = "px, ",
o._tPref3 = "px, 0px)") : (o._tPref1 = "translate(",
o._tPref2 = "px, ",
o._tPref3 = "px)"),
o._isMove ? o._slidesContainer[o._vendorPref + o._TP] = o._vendorPref + "transform" : ((c = {})[o._vendorPref + o._TP] = "opacity",
c[o._vendorPref + o._TD] = o.st.transitionSpeed + "ms",
c[o._vendorPref + o._TTF] = o.st.css3easeInOut,
r.css(c))) : (o._xProp = "left",
o._yProp = "top"),
o._slidesHorizontal && o.slider.css("touch-action", "pan-y"),
e(window).on("resize" + o.ns, (function() {
s && clearTimeout(s),
s = setTimeout((function() {
o.updateSliderSize()
}
), 50)
}
)),
o.ev.trigger("rsAfterPropsSetup"),
o.updateSliderSize(),
o.st.keyboardNavEnabled && o._bindKeyboardNav(),
o.st.arrowsNavHideOnTouch && (o.hasTouch || o.pointerMultitouch) && (o.st.arrowsNav = !1),
o.st.arrowsNav && (r = o._controlsContainer,
e('').appendTo(r),
o._arrowLeft = r.children(".rsArrowLeft").click((function(e) {
e.preventDefault(),
o.prev()
}
)),
o._arrowRight = r.children(".rsArrowRight").click((function(e) {
e.preventDefault(),
o.next()
}
)),
o.st.arrowsNavAutoHide && !o.hasTouch && (o._arrowLeft.addClass("rsHidden"),
o._arrowRight.addClass("rsHidden"),
r.one("mousemove.arrowshover", (function() {
o._arrowLeft.removeClass("rsHidden"),
o._arrowRight.removeClass("rsHidden")
}
)),
r.hover((function() {
o._arrowsAutoHideLocked || (o._arrowLeft.removeClass("rsHidden"),
o._arrowRight.removeClass("rsHidden"))
}
), (function() {
o._arrowsAutoHideLocked || (o._arrowLeft.addClass("rsHidden"),
o._arrowRight.addClass("rsHidden"))
}
))),
o.ev.on("rsOnUpdateNav", (function() {
o._updateArrowsNav()
}
)),
o._updateArrowsNav()),
o.hasTouch && o.st.sliderTouch || !o.hasTouch && o.st.sliderDrag ? (o._bindPassiveEvent(o._slidesContainer[0], o._downEvent, o._eventCallbacks.dragStart, !1),
o._bindPassiveEvent(o.slider[0], o._moveEvent, o._eventCallbacks.touchmoveFix, !1)) : o.dragSuccess = !1;
var h = ["rsPlayBtnIcon", "rsPlayBtn", "rsCloseVideoBtn", "rsCloseVideoIcn"];
o._slidesContainer.click((function(t) {
if (!o.dragSuccess) {
var n = e(t.target).attr("class");
if (-1 !== e.inArray(n, h) && o.toggleVideo())
return !1;
if (o.st.navigateByClick && !o._blockActions) {
if (e(t.target).closest(".rsNoDrag", o._currHolder).length)
return !0;
o._mouseNext(t)
}
o.ev.trigger("rsSlideClick", t)
}
}
)).on("click.rs", "a", (function(e) {
if (o.dragSuccess)
return !1;
o._blockActions = !0,
setTimeout((function() {
o._blockActions = !1
}
), 3)
}
)),
o.ev.trigger("rsAfterInit")
}
e.rsModules || (e.rsModules = {
uid: 0
}),
t.prototype = {
constructor: t,
_mouseNext: function(e) {
(e = e[this._slidesHorizontal ? "pageX" : "pageY"] - this._sliderOffset) >= this._nextSlidePos ? this.next() : 0 > e && this.prev()
},
_refreshNumPreloadImages: function() {
var e = this.st.numImagesToPreload;
(this._loop = this.st.loop) && (2 === this.numSlides ? (this._loop = !1,
this.st.loopRewind = !0) : 2 > this.numSlides && (this.st.loopRewind = this._loop = !1)),
this._loop && 0 < e && (4 >= this.numSlides ? e = 1 : this.st.numImagesToPreload > (this.numSlides - 1) / 2 && (e = Math.floor((this.numSlides - 1) / 2))),
this._numPreloadImages = e
},
_parseNode: function(t, n) {
function i(e, t) {
if (t ? r.images.push(e.attr(t)) : r.images.push(e.text()),
a) {
a = !1,
r.caption = "src" === t ? e.attr("alt") : e.contents(),
r.image = r.images[0],
r.videoURL = e.attr("data-rsVideo");
var n = e.attr("data-rsw")
, i = e.attr("data-rsh");
void 0 !== n && !1 !== n && void 0 !== i && !1 !== i ? (r.iW = parseInt(n, 10),
r.iH = parseInt(i, 10)) : o.st.imgWidth && o.st.imgHeight && (r.iW = o.st.imgWidth,
r.iH = o.st.imgHeight)
}
}
var o = this
, r = {}
, a = !0;
if (t = e(t),
o._currContent = t,
o.ev.trigger("rsBeforeParseNode", [t, r]),
!r.stopParsing) {
if (t = o._currContent,
r.id = o._idCount,
r.contentAdded = !1,
o._idCount++,
r.images = [],
r.isBig = !1,
!r.hasCover) {
if (t.hasClass("rsImg"))
var s = t
, l = !0;
else
(s = t.find(".rsImg")).length && (l = !0);
l ? (r.bigImage = s.eq(0).attr("data-rsBigImg"),
s.each((function() {
var t = e(this);
t.is("a") ? i(t, "href") : t.is("img") ? i(t, "src") : i(t)
}
))) : t.is("img") && (t.addClass("rsImg rsMainSlideImage"),
i(t, "src"))
}
return (s = t.find(".rsCaption")).length && (r.caption = s.remove()),
r.content = t,
o.ev.trigger("rsAfterParseNode", [t, r]),
n && o.slides.push(r),
0 === r.images.length && (r.isLoaded = !0,
r.isRendered = !1,
r.isLoading = !1,
r.images = null),
r
}
},
_bindKeyboardNav: function() {
var e, t, n = this, i = function(e) {
37 === e ? n.prev() : 39 === e && n.next()
};
n._doc.on("keydown" + n.ns, (function(o) {
if (!n.st.keyboardNavEnabled)
return !0;
if (!(n._isDragging || (t = o.keyCode,
37 !== t && 39 !== t || e))) {
if (document.activeElement && /(INPUT|SELECT|TEXTAREA)/i.test(document.activeElement.tagName))
return !0;
n.isFullscreen && o.preventDefault(),
i(t),
e = setInterval((function() {
i(t)
}
), 700)
}
}
)).on("keyup" + n.ns, (function(t) {
e && (clearInterval(e),
e = null)
}
))
},
goTo: function(e, t) {
e !== this.currSlideId && this._moveTo(e, this.st.transitionSpeed, !0, !t)
},
destroy: function(t) {
this.ev.trigger("rsBeforeDestroy"),
this._doc.off("keydown" + this.ns + " keyup" + this.ns),
this._eventCallbacks.dragMove && (this._unbindPassiveEvent(document, this._moveEvent, this._eventCallbacks.dragMove, !0),
this._unbindPassiveEvent(document, this._upEvent, this._eventCallbacks.dragRelease, !0)),
this._eventCallbacks.downEvent && (this._unbindPassiveEvent(this._slidesContainer[0], this._downEvent, this._eventCallbacks.dragStart, !1),
this._unbindPassiveEvent(this.slider[0], this._moveEvent, this._eventCallbacks.touchmoveFix, !1)),
this._slidesContainer.off(this._downEvent + " click"),
this.slider.data("royalSlider", null),
e.removeData(this.slider, "royalSlider"),
e(window).off("resize" + this.ns),
this.loadingTimeout && clearTimeout(this.loadingTimeout),
t && this.slider.remove(),
this.ev = this.slider = this.slides = null
},
_updateBlocksContent: function(t, n) {
function i(n, i, a) {
n.isAdded ? (o(i, n),
r(i, n)) : (a || (a = c.slidesJQ[i]),
n.holder ? a = n.holder : (a = c.slidesJQ[i] = e(a),
n.holder = a),
n.appendOnLoaded = !1,
r(i, n, a),
o(i, n),
c._addBlockToContainer(n, a, t),
n.isAdded = !0)
}
function o(e, n) {
n.contentAdded || (c.setItemHtml(n, t),
t || (n.contentAdded = !0))
}
function r(e, t, n) {
c._isMove && (n || (n = c.slidesJQ[e]),
n.css(c._reorderProp, (e + c._idOffset + y) * c._slideSize))
}
function a(e) {
if (u) {
if (e > d - 1)
return a(e - d);
if (0 > e)
return a(d + e)
}
return e
}
var s, l, c = this, u = c._loop, d = c.numSlides;
if (!isNaN(n))
return a(n);
var f = c.currSlideId
, h = t ? Math.abs(c._prevSlideId - c.currSlideId) >= c.numSlides - 1 ? 0 : 1 : c._numPreloadImages
, p = Math.min(2, h)
, m = !1
, g = !1;
for (l = f; l < f + 1 + p; l++) {
var v = a(l);
if ((s = c.slides[v]) && (!s.isAdded || !s.positionSet)) {
m = !0;
break
}
}
for (l = f - 1; l > f - 1 - p; l--)
if (v = a(l),
(s = c.slides[v]) && (!s.isAdded || !s.positionSet)) {
g = !0;
break
}
if (m)
for (l = f; l < f + h + 1; l++) {
v = a(l);
var y = Math.floor((c._realId - (f - l)) / c.numSlides) * c.numSlides;
(s = c.slides[v]) && i(s, v)
}
if (g)
for (l = f - 1; l > f - 1 - h; l--)
v = a(l),
y = Math.floor((c._realId - (f - l)) / d) * d,
(s = c.slides[v]) && i(s, v);
if (!t)
for (h = (p = a(f - h)) > (f = a(f + h)) ? 0 : p,
l = 0; l < d; l++)
p > f && l > p - 1 || !(l < h || l > f) || (s = c.slides[l]) && s.holder && (s.holder.detach(),
s.isAdded = !1)
},
setItemHtml: function(t, n) {
var i = this
, o = function() {
if (t.images) {
if (!t.isLoading) {
if (t.content.hasClass("rsImg"))
var n = t.content
, o = !0;
else
n = t.content.find(".rsImg:not(img)");
if (n && !n.is("img") && n.each((function() {
var n = e(this)
, i = ' ';
o ? t.content = e(i) : n.replaceWith(i)
}
)),
n = o ? t.content : t.content.find("img.rsImg"),
c(),
n.eq(0).addClass("rsMainSlideImage"),
t.iW && t.iH && (t.isLoaded || i._resizeImage(t),
s()),
t.isLoading = !0,
t.isBig)
e(" ").on("load.rs error.rs", (function(t) {
e(this).off("load.rs error.rs"),
r([this], !0)
}
)).attr("src", t.image);
else {
t.loaded = [],
t.numStartedLoad = 0,
n = function(n) {
e(this).off("load.rs error.rs"),
t.loaded.push(this),
t.loaded.length === t.numStartedLoad && r(t.loaded, !1)
}
;
for (var a = 0; a < t.images.length; a++) {
var l = e(" ");
t.numStartedLoad++,
l.on("load.rs error.rs", n).attr("src", t.images[a])
}
}
}
} else
t.isRendered = !0,
t.isLoaded = !0,
t.isLoading = !1,
s(!0)
}
, r = function(e, n) {
if (e.length) {
var i = e[0];
if (n !== t.isBig)
(i = t.holder.children()) && 1 < i.length && u();
else if (t.iW && t.iH)
a();
else if (t.iW = i.width,
t.iH = i.height,
t.iW && t.iH)
a();
else {
var o = new Image;
o.onload = function() {
o.width ? (t.iW = o.width,
t.iH = o.height,
a()) : setTimeout((function() {
o.width && (t.iW = o.width,
t.iH = o.height),
a()
}
), 1e3)
}
,
o.src = i.src
}
} else
a()
}
, a = function() {
t.isLoaded = !0,
t.isLoading = !1,
s(),
u(),
l()
}
, s = function() {
if (!t.isAppended && i.ev) {
var e = i.st.visibleNearby
, o = t.id - i._newSlideId;
n || t.appendOnLoaded || !i.st.fadeinLoadedSlide || 0 !== o && (!(e || i._isAnimating || i._isDragging) || -1 !== o && 1 !== o) || ((e = {
visibility: "visible",
opacity: 0
})[i._vendorPref + "transition"] = "opacity 400ms ease-in-out",
t.content.css(e),
setTimeout((function() {
t.content.css("opacity", 1)
}
), 16)),
t.holder.find(".rsPreloader").length ? t.holder.append(t.content) : t.holder.html(t.content),
t.isAppended = !0,
t.isLoaded && (i._resizeImage(t),
l()),
t.sizeReady || (t.sizeReady = !0,
setTimeout((function() {
i.ev.trigger("rsMaybeSizeReady", t)
}
), 100))
}
}
, l = function() {
!t.loadedTriggered && i.ev && (t.isLoaded = t.loadedTriggered = !0,
t.holder.trigger("rsAfterContentSet"),
i.ev.trigger("rsAfterContentSet", t))
}
, c = function() {
i.st.usePreloader && t.holder.html(i._preloader.clone())
}
, u = function(e) {
i.st.usePreloader && ((e = t.holder.find(".rsPreloader")).length && e.remove())
};
t.isLoaded ? s() : n ? !i._isMove && t.images && t.iW && t.iH ? o() : (t.holder.isWaiting = !0,
c(),
t.holder.slideId = -99) : o()
},
_addBlockToContainer: function(e, t, n) {
this._slidesContainer.append(e.holder),
e.appendOnLoaded = !1
},
_onDragStart: function(t, n) {
var i = this
, o = "touchstart" === t.type;
if (i._isTouchGesture = o,
i.ev.trigger("rsDragStart"),
e(t.target).closest(".rsNoDrag", i._currHolder).length)
return i.dragSuccess = !1,
!0;
if (!n && i._isAnimating && (i._wasAnimating = !0,
i._stopAnimation()),
i.dragSuccess = !1,
i._isDragging)
o && (i._multipleTouches = !0);
else {
if (o && (i._multipleTouches = !1),
i._setGrabbingCursor(),
o) {
var r = t.touches;
if (!(r && 0 < r.length))
return;
var a = r[0];
1 < r.length && (i._multipleTouches = !0)
} else
t.preventDefault(),
a = t;
i._isDragging = !0,
i._eventCallbacks.dragMove && (i._unbindPassiveEvent(document, i._moveEvent, i._eventCallbacks.dragMove, !0),
i._unbindPassiveEvent(document, i._upEvent, i._eventCallbacks.dragRelease, !0)),
i._eventCallbacks.dragMove = function(e) {
i._onDragMove(e, n)
}
,
i._eventCallbacks.dragRelease = function(e) {
i._onDragRelease(e, n)
}
,
i._bindPassiveEvent(document, i._moveEvent, i._eventCallbacks.dragMove, !0),
i._bindPassiveEvent(document, i._upEvent, i._eventCallbacks.dragRelease, !0),
i._currMoveAxis = "",
i._hasMoved = !1,
i._pageX = a.pageX,
i._pageY = a.pageY,
i._startPagePos = i._accelerationPos = (n ? i._thumbsHorizontal : i._slidesHorizontal) ? a.pageX : a.pageY,
i._horDir = 0,
i._verDir = 0,
i._currRenderPosition = n ? i._thumbsPosition : i._sPosition,
i._startTime = (new Date).getTime(),
o && i._sliderOverflow.on(i._cancelEvent, (function(e) {
i._onDragRelease(e, n)
}
))
}
},
_renderMovement: function(e, t) {
if (this._checkedAxis) {
var n = this._renderMoveTime
, i = e.pageX - this._pageX
, o = e.pageY - this._pageY
, r = this._currRenderPosition + i
, a = this._currRenderPosition + o
, s = t ? this._thumbsHorizontal : this._slidesHorizontal;
r = s ? r : a,
a = this._currMoveAxis,
this._hasMoved = !0,
this._pageX = e.pageX,
this._pageY = e.pageY,
"x" === a && 0 !== i ? this._horDir = 0 < i ? 1 : -1 : "y" === a && 0 !== o && (this._verDir = 0 < o ? 1 : -1),
a = s ? this._pageX : this._pageY,
i = s ? i : o,
t ? (r > this._thumbsMinPosition || r < this._thumbsMaxPosition) && (r = this._currRenderPosition + i * this._lastItemFriction) : this._loop || (0 >= this.currSlideId && 0 < a - this._startPagePos && (r = this._currRenderPosition + i * this._lastItemFriction),
this.currSlideId >= this.numSlides - 1 && 0 > a - this._startPagePos && (r = this._currRenderPosition + i * this._lastItemFriction)),
this._currRenderPosition = r,
200 < n - this._startTime && (this._startTime = n,
this._accelerationPos = a),
t ? this._setThumbsPosition(this._currRenderPosition) : this._isMove && this._setPosition(this._currRenderPosition)
}
},
_onDragMove: function(e, t) {
var n = this
, i = "touchmove" === e.type;
if (!n._isTouchGesture || i) {
if (i) {
if (n._lockAxis)
return;
var o = e.touches;
if (!o)
return;
if (1 < o.length)
return;
var r = o[0]
} else
r = e;
if (n._hasMoved || (n._useCSS3Transitions && (t ? n._thumbsContainer : n._slidesContainer).css(n._vendorPref + n._TD, "0s"),
function e() {
n._isDragging && (n._animFrame = requestAnimationFrame(e),
n._renderMoveEvent && n._renderMovement(n._renderMoveEvent, t))
}()),
n._checkedAxis)
e.preventDefault(),
n._renderMoveTime = (new Date).getTime(),
n._renderMoveEvent = r;
else if (o = t ? n._thumbsHorizontal : n._slidesHorizontal,
7 < (r = Math.abs(r.pageX - n._pageX) - Math.abs(r.pageY - n._pageY) - (o ? -7 : 7))) {
if (o)
e.preventDefault(),
n._currMoveAxis = "x";
else if (i)
return void n._completeGesture(e);
n._checkedAxis = !0
} else if (-7 > r) {
if (o) {
if (i)
return void n._completeGesture(e)
} else
e.preventDefault(),
n._currMoveAxis = "y";
n._checkedAxis = !0
}
}
},
_completeGesture: function(e, t) {
this._lockAxis = !0,
this._hasMoved = this._isDragging = !1,
this._onDragRelease(e)
},
_onDragRelease: function(t, n) {
function i(e) {
return 100 > e ? 100 : 500 < e ? 500 : e
}
function o(e, t) {
(a._isMove || n) && (g = (-a._realId - a._idOffset) * a._slideSize,
r = Math.abs(a._sPosition - g),
a._currAnimSpeed = r / t,
e && (a._currAnimSpeed += 250),
a._currAnimSpeed = i(a._currAnimSpeed),
a._animateTo(g, !1))
}
var r, a = this, s = -1 < t.type.indexOf("touch");
if (!a._isTouchGesture || s)
if (a._isTouchGesture = !1,
a.ev.trigger("rsDragRelease"),
a._renderMoveEvent = null,
a._isDragging = !1,
a._lockAxis = !1,
a._checkedAxis = !1,
a._renderMoveTime = 0,
cancelAnimationFrame(a._animFrame),
a._hasMoved && (n ? a._setThumbsPosition(a._currRenderPosition) : a._isMove && a._setPosition(a._currRenderPosition)),
a._eventCallbacks.dragMove && (a._unbindPassiveEvent(document, a._moveEvent, a._eventCallbacks.dragMove, !0),
a._unbindPassiveEvent(document, a._upEvent, a._eventCallbacks.dragRelease, !0)),
s && a._sliderOverflow.off(a._cancelEvent),
a._setGrabCursor(),
!a._hasMoved && !a._multipleTouches && n && a._thumbsEnabled) {
var l = e(t.target).closest(".rsNavItem");
l.length && a.goTo(l.index())
} else {
if (l = n ? a._thumbsHorizontal : a._slidesHorizontal,
!a._hasMoved || "y" === a._currMoveAxis && l || "x" === a._currMoveAxis && !l) {
if (n || !a._wasAnimating)
return a._wasAnimating = !1,
void (a.dragSuccess = !1);
if (a._wasAnimating = !1,
a.st.navigateByClick)
return a._mouseNext(t),
void (a.dragSuccess = !0);
a.dragSuccess = !0
} else
a.dragSuccess = !0;
a._wasAnimating = !1,
a._currMoveAxis = "";
var c = a.st.minSlideOffset;
s = s ? t.changedTouches[0] : t;
var u = l ? s.pageX : s.pageY
, d = a._startPagePos
, f = a.currSlideId
, h = a.numSlides
, p = l ? a._horDir : a._verDir
, m = a._loop;
if (s = u - a._accelerationPos,
l = (new Date).getTime() - a._startTime,
l = Math.abs(s) / l,
0 === p || 1 >= h)
o(!0, l);
else {
if (!m && !n)
if (0 >= f) {
if (0 < p)
return void o(!0, l)
} else if (f >= h - 1 && 0 > p)
return void o(!0, l);
if (n) {
var g = a._thumbsPosition;
if (g > a._thumbsMinPosition)
g = a._thumbsMinPosition;
else if (g < a._thumbsMaxPosition)
g = a._thumbsMaxPosition;
else {
u = l * l / .006;
var v = -a._thumbsPosition;
if (d = a._thumbsContainerSize - a._thumbsViewportSize + a._thumbsPosition,
0 < s && u > v ? (l = l * (v += a._thumbsViewportSize / (15 / (u / l * .003))) / u,
u = v) : 0 > s && u > d && (l = l * (d += a._thumbsViewportSize / (15 / (u / l * .003))) / u,
u = d),
v = Math.max(Math.round(l / .003), 50),
(g += u * (0 > s ? -1 : 1)) > a._thumbsMinPosition)
return void a._animateThumbsTo(g, v, !0, a._thumbsMinPosition, 200);
if (g < a._thumbsMaxPosition)
return void a._animateThumbsTo(g, v, !0, a._thumbsMaxPosition, 200)
}
a._animateThumbsTo(g, v, !0)
} else
v = function(e) {
var t = Math.floor(e / a._slideSize);
return e - t * a._slideSize > c && t++,
t
}
,
d + c < u ? 0 > p ? o(!1, l) : (v = v(u - d),
a._moveTo(a.currSlideId - v, i(Math.abs(a._sPosition - (-a._realId - a._idOffset + v) * a._slideSize) / l), !1, !0, !0)) : d - c > u ? 0 < p ? o(!1, l) : (v = v(d - u),
a._moveTo(a.currSlideId + v, i(Math.abs(a._sPosition - (-a._realId - a._idOffset - v) * a._slideSize) / l), !1, !0, !0)) : o(!1, l)
}
}
},
_setPosition: function(e) {
e = this._sPosition = e,
this._useCSS3Transitions ? this._slidesContainer.css(this._xProp, this._tPref1 + (this._slidesHorizontal ? e + this._tPref2 + 0 : 0 + this._tPref2 + e) + this._tPref3) : this._slidesContainer.css(this._slidesHorizontal ? this._xProp : this._yProp, e)
},
updateSliderSize: function(e) {
if (this.slider) {
if (this.st.autoScaleSlider) {
var t = this.st.autoScaleSliderWidth
, n = this.st.autoScaleSliderHeight;
if (this.st.autoScaleHeight) {
var i = this.slider.width();
i != this.width && (this.slider.css("height", n / t * i),
i = this.slider.width());
var o = this.slider.height()
} else
(o = this.slider.height()) != this.height && (this.slider.css("width", t / n * o),
o = this.slider.height()),
i = this.slider.width()
} else
i = this.slider.width(),
o = this.slider.height();
if (e || i != this.width || o != this.height) {
for (this.width = i,
this.height = o,
this._wrapWidth = i,
this._wrapHeight = o,
this.ev.trigger("rsBeforeSizeSet"),
this.ev.trigger("rsAfterSizePropSet"),
this._sliderOverflow.css({
width: this._wrapWidth,
height: this._wrapHeight
}),
this._slideSize = (this._slidesHorizontal ? this._wrapWidth : this._wrapHeight) + this.st.slidesSpacing,
this._imagePadding = this.st.imageScalePadding,
i = 0; i < this.slides.length; i++)
(e = this.slides[i]).positionSet = !1,
e && e.images && e.isLoaded && (e.isRendered = !1,
this._resizeImage(e));
if (this._cloneHolders)
for (i = 0; i < this._cloneHolders.length; i++)
(e = this._cloneHolders[i]).holder.css(this._reorderProp, (e.id + this._idOffset) * this._slideSize);
this._updateBlocksContent(),
this._isMove && (this._useCSS3Transitions && this._slidesContainer.css(this._vendorPref + "transition-duration", "0s"),
this._setPosition((-this._realId - this._idOffset) * this._slideSize)),
this.ev.trigger("rsOnUpdateNav")
}
this._sliderOffset = this._sliderOverflow.offset(),
this._sliderOffset = this._sliderOffset[this._reorderProp]
}
},
appendSlide: function(t, n) {
var i = this._parseNode(t);
(isNaN(n) || n > this.numSlides) && (n = this.numSlides),
this.slides.splice(n, 0, i),
this.slidesJQ.splice(n, 0, e('')),
n <= this.currSlideId && this.currSlideId++,
this.ev.trigger("rsOnAppendSlide", [i, n]),
this._refreshSlides(n),
n === this.currSlideId && this.ev.trigger("rsAfterSlideChange")
},
removeSlide: function(e) {
var t = this.slides[e];
t && (t.holder && t.holder.remove(),
e < this.currSlideId && this.currSlideId--,
this.slides.splice(e, 1),
this.slidesJQ.splice(e, 1),
this.ev.trigger("rsOnRemoveSlide", [e]),
this._refreshSlides(e),
e === this.currSlideId && this.ev.trigger("rsAfterSlideChange"))
},
_refreshSlides: function(e) {
var t = this;
for (e = t.numSlides,
e = 0 >= t._realId ? 0 : Math.floor(t._realId / e),
t.numSlides = t.slides.length,
0 === t.numSlides ? (t.currSlideId = t._idOffset = t._realId = 0,
t.currSlide = t._oldHolder = null) : t._realId = e * t.numSlides + t.currSlideId,
e = 0; e < t.numSlides; e++)
t.slides[e].id = e;
t.currSlide = t.slides[t.currSlideId],
t._currHolder = t.slidesJQ[t.currSlideId],
t.currSlideId >= t.numSlides ? t.goTo(t.numSlides - 1) : 0 > t.currSlideId && t.goTo(0),
t._refreshNumPreloadImages(),
t._isMove && t._slidesContainer.css(t._vendorPref + t._TD, "0ms"),
t._refreshSlidesTimeout && clearTimeout(t._refreshSlidesTimeout),
t._refreshSlidesTimeout = setTimeout((function() {
t._isMove && t._setPosition((-t._realId - t._idOffset) * t._slideSize),
t._updateBlocksContent(),
t._isMove || t._currHolder.css({
display: "block",
opacity: 1
})
}
), 14),
t.ev.trigger("rsOnUpdateNav")
},
_setGrabCursor: function() {
this._hasDrag && this._isMove && (this._grabCursor ? this._sliderOverflow.css("cursor", this._grabCursor) : (this._sliderOverflow.removeClass("grabbing-cursor"),
this._sliderOverflow.addClass("grab-cursor")))
},
_setGrabbingCursor: function() {
this._hasDrag && this._isMove && (this._grabbingCursor ? this._sliderOverflow.css("cursor", this._grabbingCursor) : (this._sliderOverflow.removeClass("grab-cursor"),
this._sliderOverflow.addClass("grabbing-cursor")))
},
next: function(e) {
this._moveTo("next", this.st.transitionSpeed, !0, !e)
},
prev: function(e) {
this._moveTo("prev", this.st.transitionSpeed, !0, !e)
},
_moveTo: function(e, t, n, i, o) {
var r = this;
r.ev.trigger("rsBeforeMove", [e, i]);
var a = "next" === e ? r.currSlideId + 1 : "prev" === e ? r.currSlideId - 1 : e = parseInt(e, 10);
if (!r._loop) {
if (0 > a)
return void r._doBackAndForthAnim("left", !i);
if (a >= r.numSlides)
return void r._doBackAndForthAnim("right", !i)
}
r._isAnimating && (r._stopAnimation(!0),
n = !1);
var s = a - r.currSlideId;
a = r._prevSlideId = r.currSlideId;
var l, c = r.currSlideId + s;
i = r._realId,
r._loop ? (c = r._updateBlocksContent(!1, c),
i += s) : i = c,
r._newSlideId = c,
r._oldHolder = r.slidesJQ[r.currSlideId],
r._realId = i,
r.currSlideId = r._newSlideId,
r.currSlide = r.slides[r.currSlideId],
r._currHolder = r.slidesJQ[r.currSlideId],
c = r.st.slidesDiff;
var u = 0 < s;
s = Math.abs(s);
var d = Math.floor(a / r._numPreloadImages)
, f = Math.floor((a + (u ? c : -c)) / r._numPreloadImages);
if ((d = (u ? Math.max(d, f) : Math.min(d, f)) * r._numPreloadImages + (u ? r._numPreloadImages - 1 : 0)) > r.numSlides - 1 ? d = r.numSlides - 1 : 0 > d && (d = 0),
(a = u ? d - a : a - d) > r._numPreloadImages && (a = r._numPreloadImages),
s > a + c)
for (r._idOffset += (s - (a + c)) * (u ? -1 : 1),
t *= 1.4,
a = 0; a < r.numSlides; a++)
r.slides[a].positionSet = !1;
r._currAnimSpeed = t,
r._updateBlocksContent(!0),
o || (l = !0);
var h = (-i - r._idOffset) * r._slideSize;
l ? setTimeout((function() {
r._isWorking = !1,
r._animateTo(h, e, !1, n),
r.ev.trigger("rsOnUpdateNav")
}
), 0) : (r._animateTo(h, e, !1, n),
r.ev.trigger("rsOnUpdateNav"))
},
_updateArrowsNav: function() {
this.st.arrowsNav && (1 >= this.numSlides ? (this._arrowLeft.css("display", "none"),
this._arrowRight.css("display", "none")) : (this._arrowLeft.css("display", "block"),
this._arrowRight.css("display", "block"),
this._loop || this.st.loopRewind || (0 === this.currSlideId ? this._arrowLeft.addClass("rsArrowDisabled") : this._arrowLeft.removeClass("rsArrowDisabled"),
this.currSlideId === this.numSlides - 1 ? this._arrowRight.addClass("rsArrowDisabled") : this._arrowRight.removeClass("rsArrowDisabled"))))
},
_animateTo: function(t, n, i, o, r) {
function a() {
var e;
c && (e = c.data("rsTimeout")) && (c !== u && c.css({
opacity: 0,
display: "none",
zIndex: 0
}),
clearTimeout(e),
c.data("rsTimeout", "")),
(e = u.data("rsTimeout")) && (clearTimeout(e),
u.data("rsTimeout", ""))
}
var s = this
, l = {};
if (isNaN(s._currAnimSpeed) && (s._currAnimSpeed = 400),
s._sPosition = s._currRenderPosition = t,
s.ev.trigger("rsBeforeAnimStart"),
s._useCSS3Transitions)
if (s._isMove)
s._currAnimSpeed = parseInt(s._currAnimSpeed, 10),
i = s._vendorPref + s._TTF,
l[s._vendorPref + s._TD] = s._currAnimSpeed + "ms",
l[i] = o ? e.rsCSS3Easing[s.st.easeInOut] : e.rsCSS3Easing[s.st.easeOut],
s._slidesContainer.css(l),
o || !s.hasTouch ? setTimeout((function() {
s._setPosition(t)
}
), 5) : s._setPosition(t);
else {
s._currAnimSpeed = s.st.transitionSpeed;
var c = s._oldHolder
, u = s._currHolder;
u.data("rsTimeout") && u.css("opacity", 0),
a(),
c && c.data("rsTimeout", setTimeout((function() {
l[s._vendorPref + s._TD] = "0ms",
l.zIndex = 0,
l.display = "none",
c.data("rsTimeout", ""),
c.css(l),
setTimeout((function() {
c.css("opacity", 0)
}
), 16)
}
), s._currAnimSpeed + 60)),
l.display = "block",
l.zIndex = s._fadeZIndex,
l.opacity = 0,
l[s._vendorPref + s._TD] = "0ms",
l[s._vendorPref + s._TTF] = e.rsCSS3Easing[s.st.easeInOut],
u.css(l),
u.data("rsTimeout", setTimeout((function() {
u.css(s._vendorPref + s._TD, s._currAnimSpeed + "ms"),
u.data("rsTimeout", setTimeout((function() {
u.css("opacity", 1),
u.data("rsTimeout", "")
}
), 20))
}
), 20))
}
else
s._isMove ? (l[s._slidesHorizontal ? s._xProp : s._yProp] = t + "px",
s._slidesContainer.animate(l, s._currAnimSpeed, o ? s.st.easeInOut : s.st.easeOut)) : (c = s._oldHolder,
(u = s._currHolder).stop(!0, !0).css({
opacity: 0,
display: "block",
zIndex: s._fadeZIndex
}),
s._currAnimSpeed = s.st.transitionSpeed,
u.animate({
opacity: 1
}, s._currAnimSpeed, s.st.easeInOut),
a(),
c && c.data("rsTimeout", setTimeout((function() {
c.stop(!0, !0).css({
opacity: 0,
display: "none",
zIndex: 0
})
}
), s._currAnimSpeed + 60)));
s._isAnimating = !0,
s.loadingTimeout && clearTimeout(s.loadingTimeout),
s.loadingTimeout = r ? setTimeout((function() {
s.loadingTimeout = null,
r.call()
}
), s._currAnimSpeed + 60) : setTimeout((function() {
s.loadingTimeout = null,
s._animationComplete(n)
}
), s._currAnimSpeed + 60)
},
_stopAnimation: function(e) {
if (this._isAnimating = !1,
clearTimeout(this.loadingTimeout),
this._isMove)
if (this._useCSS3Transitions) {
if (!e) {
e = this._sPosition;
var t = this._currRenderPosition = this._getTransformProp();
this._slidesContainer.css(this._vendorPref + this._TD, "0ms"),
e !== t && this._setPosition(t)
}
} else
this._slidesContainer.stop(!0),
this._sPosition = parseInt(this._slidesContainer.css(this._slidesHorizontal ? this._xProp : this._yProp), 10);
else
20 < this._fadeZIndex ? this._fadeZIndex = 10 : this._fadeZIndex++
},
_getTransformProp: function() {
var e = window.getComputedStyle(this._slidesContainer.get(0), null).getPropertyValue(this._vendorPref + "transform").replace(/^matrix\(/i, "").split(/, |\)$/g)
, t = 0 === e[0].indexOf("matrix3d");
return parseInt(e[this._slidesHorizontal ? t ? 12 : 4 : t ? 13 : 5], 10)
},
_getCSS3Prop: function(e, t) {
return this._useCSS3Transitions ? this._tPref1 + (t ? e + this._tPref2 + 0 : 0 + this._tPref2 + e) + this._tPref3 : e
},
_animationComplete: function(e) {
this._isMove || (this._currHolder.css("z-index", 0),
this._fadeZIndex = 10),
this._isAnimating = !1,
this.staticSlideId = this.currSlideId,
this._updateBlocksContent(),
this._slidesMoved = !1,
this.ev.trigger("rsAfterSlideChange")
},
_doBackAndForthAnim: function(e, t) {
var n = this
, i = (-n._realId - n._idOffset) * n._slideSize;
if (0 !== n.numSlides && !n._isAnimating)
if (n.st.loopRewind)
n.goTo("left" === e ? n.numSlides - 1 : 0, t);
else if (n._isMove) {
n._currAnimSpeed = 200;
var o = function() {
n._isAnimating = !1
};
n._animateTo(i + ("left" === e ? 30 : -30), "", !1, !0, (function() {
n._isAnimating = !1,
n._animateTo(i, "", !1, !0, o)
}
))
}
},
_detectPassiveSupport: function() {
var e = this;
if (!e._passiveChecked) {
e._passiveChecked = !0,
e._passiveParam = !1;
try {
var t = Object.defineProperty({}, "passive", {
get: function() {
e._passiveParam = {
passive: !1
}
}
});
window.addEventListener("testPassive", null, t),
window.removeEventListener("testPassive", null, t)
} catch (e) {}
}
},
_bindPassiveEvent: function(e, t, n, i) {
this._detectPassiveSupport(),
t = t.split(" ");
for (var o = 0; o < t.length; o++)
t[o] && 2 < t[o].length && e.addEventListener(t[o], n, !!i && this._passiveParam)
},
_unbindPassiveEvent: function(e, t, n, i) {
this._detectPassiveSupport(),
t = t.split(" ");
for (var o = 0; o < t.length; o++)
t[o] && 2 < t[o].length && e.removeEventListener(t[o], n, !!i && this._passiveParam)
},
_resizeImage: function(t, n) {
if (!t.isRendered) {
var i = t.content
, o = "rsMainSlideImage"
, r = e.isFunction(this.st.imageAlignCenter) ? this.st.imageAlignCenter(t) : this.st.imageAlignCenter
, a = e.isFunction(this.st.imageScaleMode) ? this.st.imageScaleMode(t) : this.st.imageScaleMode;
if (t.videoURL)
if (o = "rsVideoContainer",
"fill" !== a)
var s = !0;
else {
var l = i;
l.hasClass(o) || (l = l.find("." + o)),
l.css({
width: "100%",
height: "100%"
}),
o = "rsMainSlideImage"
}
if (i.hasClass(o) || (i = i.find("." + o)),
i) {
var c = t.iW
, u = t.iH;
if (t.isRendered = !0,
"none" !== a || r) {
o = "fill" !== a ? this._imagePadding : 0,
l = this._wrapWidth - 2 * o;
var d = this._wrapHeight - 2 * o
, f = {};
if ("fit-if-smaller" === a && (c > l || u > d) && (a = "fit"),
"fill" === a || "fit" === a) {
var h = l / c
, p = d / u;
h = "fill" == a ? h > p ? h : p : "fit" == a ? h < p ? h : p : 1,
c = Math.ceil(c * h, 10),
u = Math.ceil(u * h, 10)
}
"none" !== a && (f.width = c,
f.height = u,
s && i.find(".rsImg").css({
width: "100%",
height: "100%"
})),
r && (f.marginLeft = Math.floor((l - c) / 2) + o,
f.marginTop = Math.floor((d - u) / 2) + o),
i.css(f)
}
}
}
}
},
e.rsProto = t.prototype,
e.fn.royalSlider = function(n) {
var i = arguments;
return this.each((function() {
var o = e(this);
if ("object" !== d(n) && n) {
if ((o = o.data("royalSlider")) && o[n])
return o[n].apply(o, Array.prototype.slice.call(i, 1))
} else
o.data("royalSlider") || o.data("royalSlider", new t(o,n))
}
))
}
,
e.fn.royalSlider.defaults = {
slidesSpacing: 8,
startSlideId: 0,
loop: !1,
loopRewind: !1,
numImagesToPreload: 4,
fadeinLoadedSlide: !0,
slidesOrientation: "horizontal",
transitionType: "move",
transitionSpeed: 600,
controlNavigation: "bullets",
controlsInside: !0,
arrowsNav: !0,
arrowsNavAutoHide: !0,
navigateByClick: !0,
randomizeSlides: !1,
sliderDrag: !0,
sliderTouch: !0,
keyboardNavEnabled: !1,
fadeInAfterLoaded: !0,
allowCSS3: !0,
allowCSS3OnWebkit: !0,
addActiveClass: !1,
autoHeight: !1,
easeOut: "easeOutSine",
easeInOut: "easeInOutSine",
minSlideOffset: 10,
imageScaleMode: "fit-if-smaller",
imageAlignCenter: !0,
imageScalePadding: 4,
usePreloader: !0,
autoScaleSlider: !1,
autoScaleSliderWidth: 800,
autoScaleSliderHeight: 400,
autoScaleHeight: !0,
arrowsNavHideOnTouch: !1,
globalCaption: !1,
slidesDiff: 2
},
e.rsCSS3Easing = {
easeOutSine: "cubic-bezier(0.390, 0.575, 0.565, 1.000)",
easeInOutSine: "cubic-bezier(0.445, 0.050, 0.550, 0.950)"
},
e.extend(u.easing, {
easeInOutSine: function(e, t, n, i, o) {
return -i / 2 * (Math.cos(Math.PI * t / o) - 1) + n
},
easeOutSine: function(e, t, n, i, o) {
return i * Math.sin(t / o * (Math.PI / 2)) + n
},
easeOutCubic: function(e, t, n, i, o) {
return i * ((t = t / o - 1) * t * t + 1) + n
}
})
}(u, window),
(i = u).extend(i.rsProto, {
_initBullets: function() {
var e = this;
"bullets" === e.st.controlNavigation && (e.ev.one("rsAfterPropsSetup", (function() {
e._controlNavEnabled = !0,
e.slider.addClass("rsWithBullets");
for (var t = '', n = 0; n < e.numSlides; n++)
t += '
';
e._controlNav = t = i(t + "
"),
e._controlNavItems = t.appendTo(e.slider).children(),
e._controlNav.on("click.rs", ".rsNavItem", (function(t) {
e._thumbsDrag || e.goTo(i(this).index())
}
))
}
)),
e.ev.on("rsOnAppendSlide", (function(t, n, i) {
i >= e.numSlides ? e._controlNav.append('
') : e._controlNavItems.eq(i).before('
'),
e._controlNavItems = e._controlNav.children()
}
)),
e.ev.on("rsOnRemoveSlide", (function(t, n) {
var i = e._controlNavItems.eq(n);
i && i.length && (i.remove(),
e._controlNavItems = e._controlNav.children())
}
)),
e.ev.on("rsOnUpdateNav", (function() {
var t = e.currSlideId;
e._prevNavItem && e._prevNavItem.removeClass("rsNavSelected"),
(t = e._controlNavItems.eq(t)).addClass("rsNavSelected"),
e._prevNavItem = t
}
)))
}
}),
i.rsModules.bullets = i.rsProto._initBullets,
(o = u).extend(o.rsProto, {
_initThumbs: function() {
var e = this;
"thumbnails" === e.st.controlNavigation && (e._thumbsDefaults = {
drag: !0,
touch: !0,
orientation: "horizontal",
navigation: !0,
arrows: !0,
arrowLeft: null,
arrowRight: null,
spacing: 4,
arrowsAutoHide: !1,
appendSpan: !1,
transitionSpeed: 600,
autoCenter: !0,
fitInViewport: !0,
firstMargin: !0,
paddingTop: 0,
paddingBottom: 0
},
e.st.thumbs = o.extend({}, e._thumbsDefaults, e.st.thumbs),
e._firstThumbMoved = !0,
!1 === e.st.thumbs.firstMargin ? e.st.thumbs.firstMargin = 0 : !0 === e.st.thumbs.firstMargin && (e.st.thumbs.firstMargin = e.st.thumbs.spacing),
e.ev.on("rsBeforeParseNode", (function(e, t, n) {
t = o(t),
n.thumbnail = t.find(".rsTmb").remove(),
n.thumbnail.length ? n.thumbnail = o(document.createElement("div")).append(n.thumbnail).html() : (n.thumbnail = t.attr("data-rsTmb"),
n.thumbnail || (n.thumbnail = t.find(".rsImg").attr("data-rsTmb")),
n.thumbnail = n.thumbnail ? ' ' : "")
}
)),
e.ev.one("rsAfterPropsSetup", (function() {
e._createThumbs()
}
)),
e._prevNavItem = null,
e.ev.on("rsOnUpdateNav", (function() {
var t = o(e._controlNavItems[e.currSlideId]);
t !== e._prevNavItem && (e._prevNavItem && (e._prevNavItem.removeClass("rsNavSelected"),
e._prevNavItem = null),
e._thumbsNavigation && e._setCurrentThumb(e.currSlideId),
e._prevNavItem = t.addClass("rsNavSelected"))
}
)),
e.ev.on("rsOnAppendSlide", (function(t, n, i) {
t = "' + e._addThumbHTML + n.thumbnail + "
",
e._useCSS3Transitions && e._thumbsContainer.css(e._vendorPref + "transition-duration", "0ms"),
i >= e.numSlides ? e._thumbsContainer.append(t) : e._controlNavItems.eq(i).before(t),
e._controlNavItems = e._thumbsContainer.children(),
e.updateThumbsSize(!0)
}
)),
e.ev.on("rsOnRemoveSlide", (function(t, n) {
var i = e._controlNavItems.eq(n);
i && (e._useCSS3Transitions && e._thumbsContainer.css(e._vendorPref + "transition-duration", "0ms"),
i.remove(),
e._controlNavItems = e._thumbsContainer.children(),
e.updateThumbsSize(!0))
}
)))
},
_createThumbs: function() {
var e, t = this, n = "rsThumbs", i = t.st.thumbs, r = "", a = i.spacing;
t._controlNavEnabled = !0,
t._thumbsHorizontal = "vertical" !== i.orientation,
t._thumbsMargin = e = a ? ' style="margin-' + (t._thumbsHorizontal ? "right" : "bottom") + ":" + a + 'px;"' : "",
t._thumbsPosition = 0,
t._isThumbsAnimating = !1,
t._thumbsDrag = !1,
t._thumbsNavigation = !1,
t._thumbsArrows = i.arrows && i.navigation;
var s = t._thumbsHorizontal ? "Hor" : "Ver";
t.slider.addClass("rsWithThumbs rsWithThumbs" + s),
r += '',
t._addThumbHTML = i.appendSpan ? '
' : "";
for (var l = 0; l < t.numSlides; l++)
r += "
' + (s = t.slides[l]).thumbnail + t._addThumbHTML + "
";
r = o(r + "
"),
e = {},
i.paddingTop && (e[t._thumbsHorizontal ? "paddingTop" : "paddingLeft"] = i.paddingTop),
i.paddingBottom && (e[t._thumbsHorizontal ? "paddingBottom" : "paddingRight"] = i.paddingBottom),
r.css(e),
t._thumbsContainer = o(r).find("." + n + "Container"),
t._thumbsArrows && (n += "Arrow",
i.arrowLeft ? t._thumbsArrowLeft = i.arrowLeft : (t._thumbsArrowLeft = o(''),
r.append(t._thumbsArrowLeft)),
i.arrowRight ? t._thumbsArrowRight = i.arrowRight : (t._thumbsArrowRight = o(''),
r.append(t._thumbsArrowRight)),
t._thumbsArrowLeft.click((function() {
var e = (Math.floor(t._thumbsPosition / t._thumbSize) + t._visibleThumbsPerView) * t._thumbSize + t.st.thumbs.firstMargin;
t._animateThumbsTo(e > t._thumbsMinPosition ? t._thumbsMinPosition : e)
}
)),
t._thumbsArrowRight.click((function() {
var e = (Math.floor(t._thumbsPosition / t._thumbSize) - t._visibleThumbsPerView) * t._thumbSize + t.st.thumbs.firstMargin;
t._animateThumbsTo(e < t._thumbsMaxPosition ? t._thumbsMaxPosition : e)
}
)),
i.arrowsAutoHide && !t.hasTouch && (t._thumbsArrowLeft.css("opacity", 0),
t._thumbsArrowRight.css("opacity", 0),
r.one("mousemove.rsarrowshover", (function() {
t._thumbsNavigation && (t._thumbsArrowLeft.css("opacity", 1),
t._thumbsArrowRight.css("opacity", 1))
}
)),
r.hover((function() {
t._thumbsNavigation && (t._thumbsArrowLeft.css("opacity", 1),
t._thumbsArrowRight.css("opacity", 1))
}
), (function() {
t._thumbsNavigation && (t._thumbsArrowLeft.css("opacity", 0),
t._thumbsArrowRight.css("opacity", 0))
}
)))),
t._controlNav = r,
t._controlNavItems = t._thumbsContainer.children(),
t.msEnabled && t.st.thumbs.navigation && t._thumbsContainer.css("-ms-touch-action", t._thumbsHorizontal ? "pan-y" : "pan-x"),
t.slider.append(r),
t._thumbsEnabled = !0,
t._thumbsSpacing = a,
i.navigation && t._useCSS3Transitions && t._thumbsContainer.css(t._vendorPref + "transition-property", t._vendorPref + "transform"),
t._controlNav.on("click.rs", ".rsNavItem", (function(e) {
t._thumbsDrag || t.goTo(o(this).index())
}
)),
t.ev.off("rsBeforeSizeSet.thumbs").on("rsBeforeSizeSet.thumbs", (function() {
t._realWrapSize = t._thumbsHorizontal ? t._wrapHeight : t._wrapWidth,
t.updateThumbsSize(!0)
}
)),
t.ev.off("rsAutoHeightChange.thumbs").on("rsAutoHeightChange.thumbs", (function(e, n) {
t.updateThumbsSize(!0, n)
}
))
},
updateThumbsSize: function(e, t) {
var n = this._controlNavItems.first()
, i = {}
, o = this._controlNavItems.length;
this._thumbSize = (this._thumbsHorizontal ? n.outerWidth() : n.outerHeight()) + this._thumbsSpacing,
this._thumbsContainerSize = o * this._thumbSize - this._thumbsSpacing,
i[this._thumbsHorizontal ? "width" : "height"] = this._thumbsContainerSize + this._thumbsSpacing,
this._thumbsViewportSize = this._thumbsHorizontal ? this._controlNav.width() : void 0 !== t ? t : this._controlNav.height(),
this._thumbsEnabled && (this.isFullscreen || this.st.thumbs.fitInViewport) && (this._thumbsHorizontal ? this._wrapHeight = this._realWrapSize - this._controlNav.outerHeight() : this._wrapWidth = this._realWrapSize - this._controlNav.outerWidth()),
this._thumbsViewportSize && (this._thumbsMaxPosition = -(this._thumbsContainerSize - this._thumbsViewportSize) - this.st.thumbs.firstMargin,
this._thumbsMinPosition = this.st.thumbs.firstMargin,
this._visibleThumbsPerView = Math.floor(this._thumbsViewportSize / this._thumbSize),
this._thumbsContainerSize < this._thumbsViewportSize ? (this.st.thumbs.autoCenter ? this._setThumbsPosition((this._thumbsViewportSize - this._thumbsContainerSize) / 2) : this._setThumbsPosition(this._thumbsMinPosition),
this.st.thumbs.arrows && this._thumbsArrowLeft && (this._thumbsArrowLeft.addClass("rsThumbsArrowDisabled"),
this._thumbsArrowRight.addClass("rsThumbsArrowDisabled")),
this._thumbsDrag = this._thumbsNavigation = !1,
this._unbindPassiveEvent(this._controlNav[0], this._downEvent, this._eventCallbacks.dragStartThumb, !1)) : this.st.thumbs.navigation && !this._thumbsNavigation && (this._thumbsNavigation = !0,
!this.hasTouch && this.st.thumbs.drag || this.hasTouch && this.st.thumbs.touch) && (this._thumbsDrag = !0,
this._bindPassiveEvent(this._controlNav[0], this._downEvent, this._eventCallbacks.dragStartThumb, !1)),
this._thumbsContainer.css(i),
e && t && this._setCurrentThumb(this.currSlideId, !0))
},
setThumbsOrientation: function(e, t) {
this._thumbsEnabled && (this.st.thumbs.orientation = e,
this._controlNav.remove(),
this.slider.removeClass("rsWithThumbsHor rsWithThumbsVer"),
this._createThumbs(),
this._unbindPassiveEvent(this._controlNav[0], this._downEvent, this._eventCallbacks.dragStartThumb, !1),
t || this.updateSliderSize(!0))
},
_setThumbsPosition: function(e) {
this._thumbsPosition = e,
this._useCSS3Transitions ? this._thumbsContainer.css(this._xProp, this._tPref1 + (this._thumbsHorizontal ? e + this._tPref2 + 0 : 0 + this._tPref2 + e) + this._tPref3) : this._thumbsContainer.css(this._thumbsHorizontal ? this._xProp : this._yProp, e)
},
_animateThumbsTo: function(e, t, n, i, r) {
var a = this;
if (a._thumbsNavigation) {
t || (t = a.st.thumbs.transitionSpeed),
a._thumbsPosition = e,
a._thumbsAnimTimeout && clearTimeout(a._thumbsAnimTimeout),
a._isThumbsAnimating && (a._useCSS3Transitions || a._thumbsContainer.stop(),
n = !0);
var s = {};
a._isThumbsAnimating = !0,
a._useCSS3Transitions ? (s[a._vendorPref + "transition-duration"] = t + "ms",
s[a._vendorPref + "transition-timing-function"] = n ? o.rsCSS3Easing[a.st.easeOut] : o.rsCSS3Easing[a.st.easeInOut],
a._thumbsContainer.css(s),
a._setThumbsPosition(e)) : (s[a._thumbsHorizontal ? a._xProp : a._yProp] = e + "px",
a._thumbsContainer.animate(s, t, n ? "easeOutCubic" : a.st.easeInOut)),
i && (a._thumbsPosition = i),
a._updateThumbsArrows(),
a._thumbsAnimTimeout = setTimeout((function() {
a._isThumbsAnimating = !1,
r && (a._animateThumbsTo(i, r, !0),
r = null)
}
), t)
}
},
_updateThumbsArrows: function() {
this._thumbsArrows && (this._thumbsPosition === this._thumbsMinPosition ? this._thumbsArrowLeft.addClass("rsThumbsArrowDisabled") : this._thumbsArrowLeft.removeClass("rsThumbsArrowDisabled"),
this._thumbsPosition === this._thumbsMaxPosition ? this._thumbsArrowRight.addClass("rsThumbsArrowDisabled") : this._thumbsArrowRight.removeClass("rsThumbsArrowDisabled"))
},
_setCurrentThumb: function(e, t) {
var n = 0
, i = e * this._thumbSize + 2 * this._thumbSize - this._thumbsSpacing + this._thumbsMinPosition;
if (this._thumbsNavigation) {
if (this._firstThumbMoved && (t = !0,
this._firstThumbMoved = !1),
i + this._thumbsPosition > this._thumbsViewportSize) {
e === this.numSlides - 1 && (n = 1);
var o = -e + this._visibleThumbsPerView - 2 + n;
o = o * this._thumbSize + this._thumbsViewportSize % this._thumbSize + this._thumbsSpacing - this._thumbsMinPosition
} else
0 !== e ? (e - 1) * this._thumbSize <= -this._thumbsPosition + this._thumbsMinPosition && e - 1 <= this.numSlides - this._visibleThumbsPerView && (o = (1 - e) * this._thumbSize + this._thumbsMinPosition) : o = this._thumbsMinPosition;
o !== this._thumbsPosition && ((n = void 0 === o ? this._thumbsPosition : o) > this._thumbsMinPosition ? this._setThumbsPosition(this._thumbsMinPosition) : n < this._thumbsMaxPosition ? this._setThumbsPosition(this._thumbsMaxPosition) : void 0 !== o && (t ? this._setThumbsPosition(o) : this._animateThumbsTo(o))),
this._updateThumbsArrows()
}
}
}),
o.rsModules.thumbnails = o.rsProto._initThumbs,
(r = u).extend(r.rsProto, {
_initTabs: function() {
var e = this;
"tabs" === e.st.controlNavigation && (e.ev.on("rsBeforeParseNode", (function(e, t, n) {
t = r(t),
n.thumbnail = t.find(".rsTmb").remove(),
n.thumbnail.length ? n.thumbnail = r(document.createElement("div")).append(n.thumbnail).html() : (n.thumbnail = t.attr("data-rsTmb"),
n.thumbnail || (n.thumbnail = t.find(".rsImg").attr("data-rsTmb")),
n.thumbnail = n.thumbnail ? ' ' : "")
}
)),
e.ev.one("rsAfterPropsSetup", (function() {
e._createTabs()
}
)),
e.ev.on("rsOnAppendSlide", (function(t, n, i) {
i >= e.numSlides ? e._controlNav.append('' + n.thumbnail + "
") : e._controlNavItems.eq(i).before('' + item.thumbnail + "
"),
e._controlNavItems = e._controlNav.children()
}
)),
e.ev.on("rsOnRemoveSlide", (function(t, n) {
var i = e._controlNavItems.eq(n);
i && (i.remove(),
e._controlNavItems = e._controlNav.children())
}
)),
e.ev.on("rsOnUpdateNav", (function() {
var t = e.currSlideId;
e._prevNavItem && e._prevNavItem.removeClass("rsNavSelected"),
(t = e._controlNavItems.eq(t)).addClass("rsNavSelected"),
e._prevNavItem = t
}
)))
},
_createTabs: function() {
var e = this;
e._controlNavEnabled = !0;
for (var t = '', n = 0; n < e.numSlides; n++)
t += '
' + e.slides[n].thumbnail + "
";
t = r(t + "
"),
e._controlNav = t,
e._controlNavItems = t.children(".rsNavItem"),
e.slider.append(t),
e._controlNav.click((function(t) {
(t = r(t.target).closest(".rsNavItem")).length && e.goTo(t.index())
}
))
}
}),
r.rsModules.tabs = r.rsProto._initTabs,
function(e) {
e.extend(e.rsProto, {
_initFullscreen: function() {
var t = this;
t._fullscreenDefaults = {
enabled: !1,
keyboardNav: !0,
buttonFS: !0,
nativeFS: !1,
doubleTap: !0
},
t.st.fullscreen = e.extend({}, t._fullscreenDefaults, t.st.fullscreen),
t.st.fullscreen.enabled && t.ev.one("rsBeforeSizeSet", (function() {
t._setupFullscreen()
}
))
},
_setupFullscreen: function() {
var t = this;
if (t._fsKeyboard = !t.st.keyboardNavEnabled && t.st.fullscreen.keyboardNav,
t.st.fullscreen.nativeFS) {
var n = {
supportsFullScreen: !1,
isFullScreen: function() {
return !1
},
requestFullScreen: function() {},
cancelFullScreen: function() {},
fullScreenEventName: "",
prefix: ""
}
, i = ["webkit", "moz", "o", "ms", "khtml"];
if (void 0 !== document.cancelFullScreen)
n.supportsFullScreen = !0;
else
for (var o = 0, r = i.length; o < r; o++)
if (n.prefix = i[o],
void 0 !== document[n.prefix + "CancelFullScreen"]) {
n.supportsFullScreen = !0;
break
}
n.supportsFullScreen ? (t.nativeFS = !0,
n.fullScreenEventName = n.prefix + "fullscreenchange" + t.ns,
n.isFullScreen = function() {
switch (this.prefix) {
case "":
return document.fullScreen;
case "webkit":
return document.webkitIsFullScreen;
default:
return document[this.prefix + "FullScreen"]
}
}
,
n.requestFullScreen = function(e) {
return "" === this.prefix ? e.requestFullScreen() : e[this.prefix + "RequestFullScreen"]()
}
,
n.cancelFullScreen = function(e) {
return "" === this.prefix ? document.cancelFullScreen() : document[this.prefix + "CancelFullScreen"]()
}
,
t._fullScreenApi = n) : t._fullScreenApi = !1
}
t.st.fullscreen.buttonFS && (t._fsBtn = e('').appendTo(t._controlsContainer).on("click.rs", (function() {
t.isFullscreen ? t.exitFullscreen() : t.enterFullscreen()
}
)))
},
enterFullscreen: function(t) {
var n = this;
if (n._fullScreenApi) {
if (!t)
return n._doc.on(n._fullScreenApi.fullScreenEventName, (function(e) {
n._fullScreenApi.isFullScreen() ? n.enterFullscreen(!0) : n.exitFullscreen(!0)
}
)),
void n._fullScreenApi.requestFullScreen(e("html")[0]);
n._fullScreenApi.requestFullScreen(e("html")[0])
}
if (!n._isFullscreenUpdating) {
var i;
for (n._isFullscreenUpdating = !0,
n._doc.on("keyup" + n.ns + "fullscreen", (function(e) {
27 === e.keyCode && n.exitFullscreen()
}
)),
n._fsKeyboard && n._bindKeyboardNav(),
t = e(window),
n._fsScrollTopOnEnter = t.scrollTop(),
n._fsScrollLeftOnEnter = t.scrollLeft(),
n._htmlStyle = e("html").attr("style"),
n._bodyStyle = e("body").attr("style"),
n._sliderStyle = n.slider.attr("style"),
e("body, html").css({
overflow: "hidden",
height: "100%",
width: "100%",
margin: "0",
padding: "0"
}),
n.slider.addClass("rsFullscreen"),
i = 0; i < n.numSlides; i++)
(t = n.slides[i]).isRendered = !1,
t.bigImage && (t.isBig = !0,
t.isMedLoaded = t.isLoaded,
t.isMedLoading = t.isLoading,
t.medImage = t.image,
t.medIW = t.iW,
t.medIH = t.iH,
t.slideId = -99,
t.bigImage !== t.medImage && (t.sizeType = "big"),
t.isLoaded = t.isBigLoaded,
t.isLoading = !1,
t.image = t.bigImage,
t.images[0] = t.bigImage,
t.iW = t.bigIW,
t.iH = t.bigIH,
t.isAppended = t.contentAdded = !1,
n._updateItemSrc(t));
n.isFullscreen = !0,
n._isFullscreenUpdating = !1,
n.updateSliderSize(),
n.ev.trigger("rsEnterFullscreen")
}
},
exitFullscreen: function(t) {
var n = this;
if (n._fullScreenApi) {
if (!t)
return void n._fullScreenApi.cancelFullScreen(e("html")[0]);
n._doc.off(n._fullScreenApi.fullScreenEventName)
}
if (!n._isFullscreenUpdating) {
var i;
for (n._isFullscreenUpdating = !0,
n._doc.off("keyup" + n.ns + "fullscreen"),
n._fsKeyboard && n._doc.off("keydown" + n.ns),
e("html").attr("style", n._htmlStyle || ""),
e("body").attr("style", n._bodyStyle || ""),
i = 0; i < n.numSlides; i++)
(t = n.slides[i]).isRendered = !1,
t.bigImage && (t.isBig = !1,
t.slideId = -99,
t.isBigLoaded = t.isLoaded,
t.isBigLoading = t.isLoading,
t.bigImage = t.image,
t.bigIW = t.iW,
t.bigIH = t.iH,
t.isLoaded = t.isMedLoaded,
t.isLoading = !1,
t.image = t.medImage,
t.images[0] = t.medImage,
t.iW = t.medIW,
t.iH = t.medIH,
t.isAppended = t.contentAdded = !1,
n._updateItemSrc(t, !0),
t.bigImage !== t.medImage && (t.sizeType = "med"));
n.isFullscreen = !1,
(t = e(window)).scrollTop(n._fsScrollTopOnEnter),
t.scrollLeft(n._fsScrollLeftOnEnter),
n._isFullscreenUpdating = !1,
n.slider.removeClass("rsFullscreen"),
n.updateSliderSize(),
setTimeout((function() {
n.updateSliderSize()
}
), 1),
n.ev.trigger("rsExitFullscreen")
}
},
_updateItemSrc: function(t, n) {
var i = t.isLoaded || t.isLoading ? ' ' : ' ';
t.content.hasClass("rsImg") ? t.content = e(i) : t.content.find(".rsImg").eq(0).replaceWith(i),
t.isLoaded || t.isLoading || !t.holder || t.holder.html(t.content)
}
}),
e.rsModules.fullscreen = e.rsProto._initFullscreen
}(u),
(a = u).extend(a.rsProto, {
_initAutoplay: function() {
var e, t = this;
t._autoPlayDefaults = {
enabled: !1,
stopAtAction: !0,
pauseOnHover: !0,
delay: 2e3
},
!t.st.autoPlay && t.st.autoplay && (t.st.autoPlay = t.st.autoplay),
t.st.autoPlay = a.extend({}, t._autoPlayDefaults, t.st.autoPlay),
t.st.autoPlay.enabled && (t.ev.on("rsBeforeParseNode", (function(t, n, i) {
n = a(n),
(e = n.attr("data-rsDelay")) && (i.customDelay = parseInt(e, 10))
}
)),
t.ev.one("rsAfterInit", (function() {
t._setupAutoPlay()
}
)),
t.ev.on("rsBeforeDestroy", (function() {
t.stopAutoPlay(),
t.slider.off("mouseenter mouseleave"),
a(window).off("blur" + t.ns + " focus" + t.ns)
}
)))
},
_setupAutoPlay: function() {
var e = this;
e.startAutoPlay(),
e.ev.on("rsAfterContentSet", (function(t, n) {
e._isDragging || e._isAnimating || !e._autoPlayEnabled || n !== e.currSlide || e._play()
}
)),
e.ev.on("rsDragRelease", (function() {
e._autoPlayEnabled && e._autoPlayPaused && (e._autoPlayPaused = !1,
e._play())
}
)),
e.ev.on("rsAfterSlideChange", (function() {
e._autoPlayEnabled && e._autoPlayPaused && (e._autoPlayPaused = !1,
e.currSlide.isLoaded && e._play())
}
)),
e.ev.on("rsDragStart", (function() {
e._autoPlayEnabled && (e.st.autoPlay.stopAtAction ? e.stopAutoPlay() : (e._autoPlayPaused = !0,
e._pause()))
}
)),
e.ev.on("rsBeforeMove", (function(t, n, i) {
e._autoPlayEnabled && (i && e.st.autoPlay.stopAtAction ? e.stopAutoPlay() : (e._autoPlayPaused = !0,
e._pause()))
}
)),
e._pausedByVideo = !1,
e.ev.on("rsVideoStop", (function() {
e._autoPlayEnabled && (e._pausedByVideo = !1,
e._play())
}
)),
e.ev.on("rsVideoPlay", (function() {
e._autoPlayEnabled && (e._autoPlayPaused = !1,
e._pause(),
e._pausedByVideo = !0)
}
)),
a(window).on("blur" + e.ns, (function() {
e._autoPlayEnabled && (e._autoPlayPaused = !0,
e._pause())
}
)).on("focus" + e.ns, (function() {
e._autoPlayEnabled && e._autoPlayPaused && (e._autoPlayPaused = !1,
e._play())
}
)),
e.st.autoPlay.pauseOnHover && (e._pausedByHover = !1,
e.slider.hover((function() {
e._autoPlayEnabled && (e._autoPlayPaused = !1,
e._pause(),
e._pausedByHover = !0)
}
), (function() {
e._autoPlayEnabled && (e._pausedByHover = !1,
e._play())
}
)))
},
toggleAutoPlay: function() {
this._autoPlayEnabled ? this.stopAutoPlay() : this.startAutoPlay()
},
startAutoPlay: function() {
this._autoPlayEnabled = !0,
this.currSlide.isLoaded && this._play()
},
stopAutoPlay: function() {
this._pausedByVideo = this._pausedByHover = this._autoPlayPaused = this._autoPlayEnabled = !1,
this._pause()
},
_play: function() {
var e = this;
e._pausedByHover || e._pausedByVideo || (e._autoPlayRunning = !0,
e._autoPlayTimeout && clearTimeout(e._autoPlayTimeout),
e._autoPlayTimeout = setTimeout((function() {
if (!e._loop && !e.st.loopRewind) {
var t = !0;
e.st.loopRewind = !0
}
e.next(!0),
t && (e.st.loopRewind = !1)
}
), e.currSlide.customDelay ? e.currSlide.customDelay : e.st.autoPlay.delay))
},
_pause: function() {
this._pausedByHover || this._pausedByVideo || (this._autoPlayRunning = !1,
this._autoPlayTimeout && (clearTimeout(this._autoPlayTimeout),
this._autoPlayTimeout = null))
}
}),
a.rsModules.autoplay = a.rsProto._initAutoplay,
(s = u).extend(s.rsProto, {
_initVideo: function() {
var e = this;
e._videoDefaults = {
autoHideArrows: !0,
autoHideControlNav: !1,
autoHideBlocks: !1,
autoHideCaption: !1,
disableCSS3inFF: !0,
youTubeCode: 'VIDEO ',
vimeoCode: ''
},
e.st.video = s.extend({}, e._videoDefaults, e.st.video),
e.ev.on("rsBeforeSizeSet", (function() {
e._isVideoPlaying && setTimeout((function() {
var t = e._currHolder;
t = t.hasClass("rsVideoContainer") ? t : t.find(".rsVideoContainer"),
e._videoFrameHolder && e._videoFrameHolder.css({
width: t.width(),
height: t.height()
})
}
), 32)
}
));
var t = e._browser.mozilla;
e.ev.on("rsAfterParseNode", (function(n, i, o) {
if (n = s(i),
o.videoURL) {
e.st.video.disableCSS3inFF && t && (e._useCSS3Transitions = e._use3dTransform = !1),
i = s('
');
var r = s('');
n.hasClass("rsImg") ? o.content = i.append(n).append(r) : o.content.find(".rsImg").wrap(i).after(r)
}
}
)),
e.ev.on("rsAfterSlideChange", (function() {
e.stopVideo()
}
))
},
toggleVideo: function() {
return this._isVideoPlaying ? this.stopVideo() : this.playVideo()
},
playVideo: function() {
var e = this;
if (!e._isVideoPlaying) {
var t = e.currSlide;
if (!t.videoURL)
return !1;
e._playingVideoSlide = t;
var n, i = e._currVideoContent = t.content;
if ((t = t.videoURL).match(/youtu\.be/i) || t.match(/youtube\.com/i)) {
var o = /^.*(youtu\.be\/|v\/|u\/\w\/|embed\/|watch\?v=|&v=)([^#&\?]*).*/;
(o = t.match(o)) && 11 == o[2].length && (n = o[2]),
void 0 !== n && (e._videoFrameHolder = e.st.video.youTubeCode.replace("%id%", n))
} else
t.match(/vimeo\.com/i) && (o = /(www\.)?vimeo.com\/(\d+)($|\/)/,
(o = t.match(o)) && (n = o[2]),
void 0 !== n && (e._videoFrameHolder = e.st.video.vimeoCode.replace("%id%", n)));
return e.videoObj = s(e._videoFrameHolder),
e.ev.trigger("rsOnCreateVideoElement", [t]),
e.videoObj.length && (e._videoFrameHolder = s(''),
e._videoFrameHolder.find(".rsPreloader").after(e.videoObj),
i = i.hasClass("rsVideoContainer") ? i : i.find(".rsVideoContainer"),
e._videoFrameHolder.css({
width: i.width(),
height: i.height()
}).find(".rsCloseVideoBtn").off("click.rsv").on("click.rsv", (function(t) {
return e.stopVideo(),
t.preventDefault(),
t.stopPropagation(),
!1
}
)),
i.append(e._videoFrameHolder),
e.isIPAD && i.addClass("rsIOSVideo"),
e._toggleHiddenClass(!1),
setTimeout((function() {
e._videoFrameHolder.addClass("rsVideoActive")
}
), 10),
e.ev.trigger("rsVideoPlay"),
e._isVideoPlaying = !0),
!0
}
return !1
},
stopVideo: function() {
var e = this;
return !!e._isVideoPlaying && (e.isIPAD && e.slider.find(".rsCloseVideoBtn").remove(),
e._toggleHiddenClass(!0),
setTimeout((function() {
e.ev.trigger("rsOnDestroyVideoElement", [e.videoObj]);
var t = e._videoFrameHolder.find("iframe");
if (t.length)
try {
t.attr("src", "")
} catch (e) {}
e._videoFrameHolder.remove(),
e._videoFrameHolder = null
}
), 16),
e.ev.trigger("rsVideoStop"),
e._isVideoPlaying = !1,
!0)
},
_toggleHiddenClass: function(e, t) {
var n = []
, i = this.st.video;
if (i.autoHideArrows && (this._arrowLeft && (n.push(this._arrowLeft, this._arrowRight),
this._arrowsAutoHideLocked = !e),
this._fsBtn && n.push(this._fsBtn)),
i.autoHideControlNav && this._controlNav && n.push(this._controlNav),
i.autoHideBlocks && this._playingVideoSlide.animBlocks && n.push(this._playingVideoSlide.animBlocks),
i.autoHideCaption && this.globalCaption && n.push(this.globalCaption),
this.slider[e ? "removeClass" : "addClass"]("rsVideoPlaying"),
n.length)
for (i = 0; i < n.length; i++)
e ? n[i].removeClass("rsHidden") : n[i].addClass("rsHidden")
}
}),
s.rsModules.video = s.rsProto._initVideo,
(l = u).extend(l.rsProto, {
_initAnimatedBlocks: function() {
function e() {
var e = n.currSlide;
if (n.currSlide && n.currSlide.isLoaded && n._slideWithBlocks !== e) {
if (0 < n._animatedBlockTimeouts.length) {
for (t = 0; t < n._animatedBlockTimeouts.length; t++)
clearTimeout(n._animatedBlockTimeouts[t]);
n._animatedBlockTimeouts = []
}
if (0 < n._blockAnimProps.length) {
var i;
for (t = 0; t < n._blockAnimProps.length; t++)
(i = n._blockAnimProps[t]) && (n._useCSS3Transitions ? (i.block.css(n._vendorPref + n._TD, "0s"),
i.block.css(i.css)) : i.block.stop(!0).css(i.css),
n._slideWithBlocks = null,
e.animBlocksDisplayed = !1);
n._blockAnimProps = []
}
e.animBlocks && (e.animBlocksDisplayed = !0,
n._slideWithBlocks = e,
n._animateBlocks(e.animBlocks))
}
}
var t, n = this;
n._blockDefaults = {
fadeEffect: !0,
moveEffect: "top",
moveOffset: 20,
speed: 400,
easing: "easeOutSine",
delay: 200
},
n.st.block = l.extend({}, n._blockDefaults, n.st.block),
n._blockAnimProps = [],
n._animatedBlockTimeouts = [],
n.ev.on("rsAfterInit", (function() {
e()
}
)),
n.ev.on("rsBeforeParseNode", (function(e, t, n) {
t = l(t),
n.animBlocks = t.find(".rsABlock").css("display", "none"),
n.animBlocks.length || (t.hasClass("rsABlock") ? n.animBlocks = t.css("display", "none") : n.animBlocks = !1)
}
)),
n.ev.on("rsAfterContentSet", (function(t, i) {
i.id === n.slides[n.currSlideId].id && setTimeout((function() {
e()
}
), n.st.fadeinLoadedSlide ? 300 : 0)
}
)),
n.ev.on("rsAfterSlideChange", (function() {
e()
}
))
},
_updateAnimBlockProps: function(e, t) {
setTimeout((function() {
e.css(t)
}
), 6)
},
_animateBlocks: function(e) {
var t, n, i, o, r, a, s, c = this;
c._animatedBlockTimeouts = [],
e.each((function(e) {
t = l(this),
n = {},
i = {},
o = null;
var u = t.attr("data-move-offset");
if (0 < (u = u ? parseInt(u, 10) : c.st.block.moveOffset) && ((a = t.data("move-effect")) ? ("none" === (a = a.toLowerCase()) || "left" !== a && "top" !== a && "bottom" !== a && "right" !== a && "none" === (a = c.st.block.moveEffect)) && (a = !1) : a = c.st.block.moveEffect,
a && "none" !== a)) {
var d = "right" === a || "left" === a;
if (s = !1,
c._useCSS3Transitions) {
var f = 0;
r = c._xProp
} else
d ? isNaN(parseInt(t.css("right"), 10)) ? r = "left" : (r = "right",
s = !0) : isNaN(parseInt(t.css("bottom"), 10)) ? r = "top" : (r = "bottom",
s = !0),
r = "margin-" + r,
s && (u = -u),
c._useCSS3Transitions ? f = parseInt(t.css(r), 10) : void 0 === (f = t.data("rs-start-move-prop")) && (f = parseInt(t.css(r), 10),
isNaN(f) && (f = 0),
t.data("rs-start-move-prop", f));
i[r] = c._getCSS3Prop("top" === a || "left" === a ? f - u : f + u, d),
n[r] = c._getCSS3Prop(f, d)
}
(u = t.attr("data-fade-effect")) ? "none" !== u.toLowerCase() && "false" !== u.toLowerCase() || (u = !1) : u = c.st.block.fadeEffect,
u && (i.opacity = 0,
n.opacity = 1),
(u || a) && ((o = {}).hasFade = !!u,
a && (o.moveProp = r,
o.hasMove = !0),
o.speed = t.data("speed"),
isNaN(o.speed) && (o.speed = c.st.block.speed),
o.easing = t.data("easing"),
o.easing || (o.easing = c.st.block.easing),
o.css3Easing = l.rsCSS3Easing[o.easing],
o.delay = t.data("delay"),
isNaN(o.delay) && (o.delay = c.st.block.delay * e)),
u = {},
c._useCSS3Transitions && (u[c._vendorPref + c._TD] = "0ms"),
u.moveProp = n.moveProp,
u.opacity = n.opacity,
u.display = "none",
c._blockAnimProps.push({
block: t,
css: u
}),
c._updateAnimBlockProps(t, i),
c._animatedBlockTimeouts.push(setTimeout(function(e, t, n, i) {
return function() {
if (e.css("display", "block"),
n) {
var o = {};
if (c._useCSS3Transitions) {
var r = "";
n.hasMove && (r += n.moveProp),
n.hasFade && (n.hasMove && (r += ", "),
r += "opacity"),
o[c._vendorPref + c._TP] = r,
o[c._vendorPref + c._TD] = n.speed + "ms",
o[c._vendorPref + c._TTF] = n.css3Easing,
e.css(o),
setTimeout((function() {
e.css(t)
}
), 24)
} else
setTimeout((function() {
e.animate(t, n.speed, n.easing)
}
), 16)
}
delete c._animatedBlockTimeouts[i]
}
}(t, n, o, e), 6 >= o.delay ? 12 : o.delay))
}
))
}
}),
l.rsModules.animatedBlocks = l.rsProto._initAnimatedBlocks,
function(e) {
e.extend(e.rsProto, {
_initAutoHeight: function() {
var e = this;
if (e.st.autoHeight) {
var t, n, i, o = !0, r = function(r) {
i = e.slides[e.currSlideId],
(t = i.holder) && (n = t.height()) && void 0 !== n && n > (e.st.minAutoHeight || 30) && (e._wrapHeight = n,
e._useCSS3Transitions || !r ? e._sliderOverflow.css("height", n) : e._sliderOverflow.stop(!0, !0).animate({
height: n
}, e.st.transitionSpeed),
e.ev.trigger("rsAutoHeightChange", n),
o && (e._useCSS3Transitions && setTimeout((function() {
e._sliderOverflow.css(e._vendorPref + "transition", "height " + e.st.transitionSpeed + "ms ease-in-out")
}
), 16),
o = !1))
};
e.ev.on("rsMaybeSizeReady.rsAutoHeight", (function(e, t) {
i === t && r()
}
)),
e.ev.on("rsAfterContentSet.rsAutoHeight", (function(e, t) {
i === t && r()
}
)),
e.slider.addClass("rsAutoHeight"),
e.ev.one("rsAfterInit", (function() {
setTimeout((function() {
r(!1),
setTimeout((function() {
e.slider.append('
')
}
), 16)
}
), 16)
}
)),
e.ev.on("rsBeforeAnimStart", (function() {
r(!0)
}
)),
e.ev.on("rsBeforeSizeSet", (function() {
setTimeout((function() {
r(!1)
}
), 16)
}
))
}
}
}),
e.rsModules.autoHeight = e.rsProto._initAutoHeight
}(u),
function(e) {
e.extend(e.rsProto, {
_initGlobalCaption: function() {
var t = this;
t.st.globalCaption && (t.ev.on("rsAfterInit", (function() {
t.globalCaption = e('
').appendTo(t.st.globalCaptionInside ? t._sliderOverflow : t.slider),
t.globalCaption.html(t.currSlide.caption || "")
}
)),
t.ev.on("rsBeforeAnimStart", (function() {
t.globalCaption.html(t.currSlide.caption || "")
}
)))
}
}),
e.rsModules.globalCaption = e.rsProto._initGlobalCaption
}(u),
function(e) {
e.rsProto._initActiveClass = function() {
var e, t = this;
t.st.addActiveClass && t.ev.on("rsOnUpdateNav", (function() {
e && clearTimeout(e),
e = setTimeout((function() {
t._oldHolder && t._oldHolder.removeClass("rsActiveSlide"),
t._currHolder && t._currHolder.addClass("rsActiveSlide"),
e = null
}
), 50)
}
))
}
,
e.rsModules.activeClass = e.rsProto._initActiveClass
}(u),
function(e) {
e.extend(e.rsProto, {
_initDeeplinking: function() {
var t, n, i, o = this;
if (o._hashDefaults = {
enabled: !1,
change: !1,
prefix: ""
},
o.st.deeplinking = e.extend({}, o._hashDefaults, o.st.deeplinking),
o.st.deeplinking.enabled) {
var r = o.st.deeplinking.change
, a = o.st.deeplinking.prefix
, s = "#" + a
, l = function() {
var e = window.location.hash;
return e && 0 < e.indexOf(a) && 0 <= (e = parseInt(e.substring(s.length), 10)) ? e - 1 : -1
}
, c = l();
-1 !== c && (o.st.startSlideId = c),
r && (e(window).on("hashchange" + o.ns, (function(e) {
t || (0 > (e = l()) || (e > o.numSlides - 1 && (e = o.numSlides - 1),
o.goTo(e)))
}
)),
o.ev.on("rsBeforeAnimStart", (function() {
n && clearTimeout(n),
i && clearTimeout(i)
}
)),
o.ev.on("rsAfterSlideChange", (function() {
n && clearTimeout(n),
i && clearTimeout(i),
i = setTimeout((function() {
t = !0,
window.location.replace(("" + window.location).split("#")[0] + s + (o.currSlideId + 1)),
n = setTimeout((function() {
t = !1,
n = null
}
), 60)
}
), 400)
}
))),
o.ev.on("rsBeforeDestroy", (function() {
n = i = null,
r && e(window).off("hashchange" + o.ns)
}
))
}
}
}),
e.rsModules.deeplinking = e.rsProto._initDeeplinking
}(u),
function(e, t, n) {
function i(e) {
return "#" + (e = e || location.href).replace(/^[^#]*#?(.*)$/, "$1")
}
var o = document
, r = e.event.special
, a = o.documentMode
, s = "onhashchange"in t && (a === n || 7 < a);
e.fn.hashchange = function(e) {
return e ? this.bind("hashchange", e) : this.trigger("hashchange")
}
,
e.fn.hashchange.delay = 50,
r.hashchange = e.extend(r.hashchange, {
setup: function() {
if (s)
return !1;
e(l.start)
},
teardown: function() {
if (s)
return !1;
e(l.stop)
}
});
var l = function() {
function r() {
var n = i()
, o = f(c);
n !== c ? (d(c = n, o),
e(t).trigger("hashchange")) : o !== c && (location.href = location.href.replace(/#.*/, "") + o),
a = setTimeout(r, e.fn.hashchange.delay)
}
var a, l = {}, c = i(), u = function(e) {
return e
}, d = u, f = u;
return l.start = function() {
a || r()
}
,
l.stop = function() {
a && clearTimeout(a),
a = n
}
,
t.attachEvent && !t.addEventListener && !s && function() {
var t, n;
l.start = function() {
t || (n = (n = e.fn.hashchange.src) && n + i(),
t = e('').hide().one("load", (function() {
n || d(i()),
r()
}
)).attr("src", n || "javascript:0").insertAfter("body")[0].contentWindow,
o.onpropertychange = function() {
try {
"title" === event.propertyName && (t.document.title = o.title)
} catch (e) {}
}
)
}
,
l.stop = u,
f = function() {
return i(t.location.href)
}
,
d = function(n, i) {
var r = t.document
, a = e.fn.hashchange.domain;
n !== i && (r.title = o.title,
r.open(),
a && r.write('