');
var n = "video, rs-poster, .tp-video-play-button";
void 0 !== s.poster && s.controls && (n = ".tp-video-play-button"), e.find(n).on("click", function () {
!1 === s.loop && s.esec > 0 && s.esec <= s.video.currentTime || (e.hasClass("videoisplaying") ? t.stopVideo(e, i) : t.playVideo(e, i, !0))
})
}
(e.hasClass("rs-fsv") || s.bgvideo) && (s.bgvideo || e.hasClass("rs-fsv") ? (s.html5vid.addClass("fullcoveredvideo"), void 0 !== s.ratio && 1 != s.ratio.split(":").length || (s.ratio = "16:9"), t.prepareCoveredVideo(i)) : s.html5vid.addClass("rs-fsv")), a(s.video, "canplaythrough", function () {
t.preLoadAudioDone(e, i, "canplaythrough")
}), a(s.video, "canplay", function () {
t.preLoadAudioDone(e, i, "canplay")
}), a(s.video, "progress", function () {
t.preLoadAudioDone(e, i, "progress")
}), a(s.video, "pause", function () {
t.ISM && b(s, 1)
}), a(s.video, "timeupdate", function (e) {
this.BGrendered = !0, p(i, s), -1 === s.esec && s.loop && 1 == window.isSafari11 && (s.esec = s.video.duration - .075), void 0 !== s.lastCurrentTime ? s.fps = s.video.currentTime - s.lastCurrentTime : s.fps = .1, s.lastCurrentTime = s.video.currentTime, 0 != s.esec && -1 != s.esec && s.esec < s.video.currentTime && !s.nextslidecalled && (s.loop ? (l(s, void 0, i), s.video.currentTime = -1 === s.ssec ? .5 : s.ssec) : (s.nse && (s.nseTriggered = !0, s.nextslidecalled = !0, t[i].jcnah = !0, t[i].c.revnext(), setTimeout(function () {
t[i].jcnah = !1
}, 1e3)), s.video.pause()))
}), a(s.video, "play", function () {
s.cSS = "playing", p(i, s), s.bgvideo && (s.nBG.drawVideoCanvasImagesRecall = !0, s.nBG.videoisplaying = !0, s.nBG.video = s.video, t.updateVideoFrames(i, s.nBG)), t[i].onceVideoPlayed = !0, s.nextslidecalled = !1, s.volume = null != s.volume && "mute" != s.volume ? parseFloat(s.volcache) : s.volume, s.volcache = null != s.volcache && "mute" != s.volcache ? parseFloat(s.volcache) : s.volcache, t.is_mobile() || (!0 === t[i].globalmute ? s.video.muted = !0 : s.video.muted = "mute" == s.volume, s.volcache = t.isNumeric(s.volcache) && s.volcache > 1 ? s.volcache / 100 : s.volcache, "mute" == s.volume ? s.video.muted = !0 : null != s.volcache && (s.video.volume = s.volcache)), e.addClass("videoisplaying"), y(e, i), clearTimeout(s.showCoverSoon), !0 !== s.pausetimer || "audio" == s.tag ? (t[i].stopByVideo = !1, t[i].c.trigger("revolution.slide.onvideostop", r(s.video, "html5", s))) : (t[i].stopByVideo = !0, t[i].c.trigger("revolution.slide.onvideoplay", r(s.video, "html5", s))), s.pausetimer && "playing" == t[i].sliderstatus && (t[i].stopByVideo = !0, t[i].c.trigger("stoptimer")), t.toggleState(s.videotoggledby)
}), a(s.video, "seeked", function () {
s.seeking = !1
}), a(s.video, "seeking", function () {
s.seeking = !0
}), a(s.video, "pause", function (a) {
s.cSS = "paused", p(i, s), e.removeClass("videoisplaying"), s.bgvideo && (s.nBG.drawVideoCanvasImagesRecall = !1, s.nBG.videoisplaying = !1), t[i].stopByVideo = !1, w(e, i), "audio" != s.tag && t[i].c.trigger("starttimer"), t[i].c.trigger("revolution.slide.onvideostop", r(s.video, "html5", s)), null != t[i].videoIsPlaying && t[i].videoIsPlaying.attr("id") != e.attr("id") || t.unToggleState(s.videotoggledby)
}), a(s.video, "ended", function () {
s.cSS = "paused", document.fullscreenElement !== s.video && document.webkitFullscreenElement !== s.video || h(), p(i, s), w(e, i), t[i].stopByVideo = !1, w(e, i), "audio" != s.tag && t[i].c.trigger("starttimer"), t[i].c.trigger("revolution.slide.onvideostop", r(s.video, "html5", e.data())), s.nse && s.video.currentTime > 0 && (1 == !t[i].jcnah && (s.nseTriggered = !0, t[i].c.revnext(), t[i].jcnah = !0), setTimeout(function () {
t[i].jcnah = !1
}, 1500)), e.removeClass("videoisplaying"), s.bgvideo && (s.nBG.drawVideoCanvasImagesRecall = !1, s.nBG.videoisplaying = !1), !0 !== t[i].inviewport && void 0 !== t[i].inviewport || (t[i].lastplayedvideos = [])
}), a(s.video, "volumechange", function () {
s.video.muted ? s.volume = "mute" : s.volume = s.volcache = s.video.volume
})
}, v = function (e) {
return "t" === e || !0 === e || "true" === e || "f" !== e && !1 !== e && "false" !== e && e
}, f = function (e, t, a) {
e.audio = "audio" === t;
var r = void 0 === e.video ? [] : e.video.split(";"), o = {
volume: e.audio ? 1 : "mute",
pload: "auto",
ratio: "16:9",
loop: !0,
aplay: "true",
fitCover: !0,
afs: !0,
controls: !1,
nse: !0,
npom: !1,
opom: !1,
inline: !0,
notonmobile: !1,
start: -1,
end: -1,
doverlay: "none",
doverlaysize: 1,
doverlaycolora: "transparent",
doverlaycolorb: "#000000",
scop: !1,
rwd: !0,
speed: 1,
ploadwait: 5,
stopAV: 1 !== e.bgvideo,
noInt: !1,
volcache: 75,
crossOriginVideo: !1
};
for (var s in r) if (r.hasOwnProperty(s)) {
var n = r[s].split(":");
switch (n[0]) {
case"v":
o.volume = n[1];
break;
case"twa":
o.twaudio = n[1];
break;
case"vd":
o.volcache = n[1];
break;
case"p":
o.pload = n[1];
break;
case"ar":
o.ratio = n[1] + (void 0 !== n[2] ? ":" + n[2] : "");
break;
case"ap":
o.aplay = v(n[1]);
break;
case"vfc":
o.fitCover = v(n[1]);
break;
case"afs":
o.afs = v(n[1]);
break;
case"vc":
o.controls = n[1];
break;
case"nse":
o.nse = v(n[1]);
break;
case"npom":
o.npom = v(n[1]);
break;
case"opom":
o.opom = v(n[1]);
break;
case"t":
o.vtype = n[1];
break;
case"inl":
o.inline = v(n[1]);
break;
case"nomo":
o.notonmobile = v(n[1]);
break;
case"sta":
o.start = n[1] + (void 0 !== n[2] ? ":" + n[2] : "");
break;
case"end":
o.end = n[1] + (void 0 !== n[2] ? ":" + n[2] : "");
break;
case"do":
o.doverlay = n[1];
break;
case"dos":
o.doverlaysize = n[1];
break;
case"doca":
o.doverlaycolora = n[1];
break;
case"docb":
o.doverlaycolorb = n[1];
break;
case"scop":
o.scop = v(n[1]);
break;
case"rwd":
o.rwd = v(n[1]);
break;
case"sp":
o.speed = n[1];
break;
case"vw":
o.ploadwait = parseInt(n[1], 0) || 5;
break;
case"sav":
o.stopAV = v(n[1]);
break;
case"noint":
o.noInt = v(n[1]);
break;
case"l":
o.loopcache = n[1], o.loop = "loop" === n[1] || "loopandnoslidestop" === n[1] || "none" !== n[1] && v(n[1]);
break;
case"ptimer":
o.pausetimer = v(n[1]);
break;
case"sat":
o.waitToSlideTrans = v(n[1]);
break;
case"crossOriginVideo":
o.crossOriginVideo = v(n[1]);
break;
case"poch":
o.pauseOnSlideChange = v(n[1])
}
}
return null == e.mp4 && null == e.webm && (o.fitCover = !1), void 0 !== e.bgvideo && (o.bgvideo = e.bgvideo), o.noInt && (o.controls = !1), void 0 !== e.mp4 && (o.mp4 = e.mp4), void 0 !== e.videomp4 && (o.mp4 = e.videomp4), void 0 !== e.ytid && (o.ytid = e.ytid), void 0 !== e.ogv && (o.ogv = e.ogv), void 0 !== e.webm && (o.webm = e.webm), void 0 !== e.vimeoid && (o.vimeoid = e.vimeoid), void 0 !== e.vatr && (o.vatr = e.vatr), void 0 !== e.videoattributes && (o.vatr = e.videoattributes), void 0 !== e.poster && (o.poster = e.poster), o.slideid = a, o.aplay = "true" === o.aplay || o.aplay, 1 === o.bgvideo && (o.volume = "mute"), o.ssec = i(o.start), o.esec = i(o.end), o.pausetimer = void 0 === o.pausetimer ? "loopandnoslidestop" !== o.loopcache : o.pausetimer, o.inColumn = e._incolumn, o.audio = e.audio, !0 !== o.loop && "true" !== o.loop || !0 !== o.nse && "true" !== o.nse || (o.loop = !1), o.aplay && o.twaudio && !o.bgvideo && (o.twaudio = !0), o
}, y = function (e, i) {
if (t[i].playingvideos = void 0 === t[i].playingvideos ? new Array : t[i].playingvideos, t[i].videos[e[0].id].stopAV && void 0 !== t[i].playingvideos && t[i].playingvideos.length > 0) for (var a in t[i].lastplayedvideos = jQuery.extend(!0, [], t[i].playingvideos), t[i].playingvideos) t[i].playingvideos.hasOwnProperty(a) && t.stopVideo(t[i].playingvideos[a], i);
t[i].playingvideos.push(e), t[i].videoIsPlaying = e
}, w = function (e, i) {
void 0 !== t[i] && void 0 !== t[i] && null != t[i].playingvideos && jQuery.inArray(e, t[i].playingvideos) >= 0 && t[i].playingvideos.splice(jQuery.inArray(e, t[i].playingvideos), 1)
}, b = function (e, i) {
if (void 0 !== e && (void 0 === i && (i = 0), t.ISM && !e.bgvideo)) {
e.playPauseBtnTween && e.playPauseBtnTween.kill && e.playPauseBtnTween.kill();
var a = t.closestNode(e.video, "RS-LAYER"), r = e.controls ? 1 : 0, o = e.controls ? 0 : .3;
e.controls && e.poster && 0 === i && (o = 0, r = 0), a && (e.playPauseBtnTween = tpGS.gsap.to(a.querySelector(".tp-video-play-button"), {
duration: o,
delay: r,
opacity: i
}))
}
};
window.RS_MODULES = window.RS_MODULES || {}, window.RS_MODULES.video = {
loaded: !0,
version: "6.6.9"
}, window.RS_MODULES.checkMinimal && window.RS_MODULES.checkMinimal()
}(jQuery);
/*! jQuery UI - v1.13.2 - 2022-07-14
* http://jqueryui.com
* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-patch.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js
* Copyright jQuery Foundation and other contributors; Licensed MIT */
!function (t) {
"use strict";
"function" == typeof define && define.amd ? define(["jquery"], t) : t(jQuery)
}(function (x) {
"use strict";
var t, e, i, n, W, C, o, s, r, l, a, h, u;
function E(t, e, i) {
return [parseFloat(t[0]) * (a.test(t[0]) ? e / 100 : 1), parseFloat(t[1]) * (a.test(t[1]) ? i / 100 : 1)]
}
function L(t, e) {
return parseInt(x.css(t, e), 10) || 0
}
function N(t) {
return null != t && t === t.window
}
x.ui = x.ui || {}, x.ui.version = "1.13.2",
/*!
* jQuery UI :data 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.extend(x.expr.pseudos, {
data: x.expr.createPseudo ? x.expr.createPseudo(function (e) {
return function (t) {
return !!x.data(t, e)
}
}) : function (t, e, i) {
return !!x.data(t, i[3])
}
}),
/*!
* jQuery UI Disable Selection 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.fn.extend({
disableSelection: (t = "onselectstart" in document.createElement("div") ? "selectstart" : "mousedown", function () {
return this.on(t + ".ui-disableSelection", function (t) {
t.preventDefault()
})
}), enableSelection: function () {
return this.off(".ui-disableSelection")
}
}),
/*!
* jQuery UI Focusable 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.ui.focusable = function (t, e) {
var i, n, o, s = t.nodeName.toLowerCase();
return "area" === s ? (o = (i = t.parentNode).name, !(!t.href || !o || "map" !== i.nodeName.toLowerCase()) && 0 < (i = x("img[usemap='#" + o + "']")).length && i.is(":visible")) : (/^(input|select|textarea|button|object)$/.test(s) ? (n = !t.disabled) && (o = x(t).closest("fieldset")[0]) && (n = !o.disabled) : n = "a" === s && t.href || e, n && x(t).is(":visible") && function (t) {
var e = t.css("visibility");
for (; "inherit" === e;) t = t.parent(), e = t.css("visibility");
return "visible" === e
}(x(t)))
}, x.extend(x.expr.pseudos, {
focusable: function (t) {
return x.ui.focusable(t, null != x.attr(t, "tabindex"))
}
}), x.fn._form = function () {
return "string" == typeof this[0].form ? this.closest("form") : x(this[0].form)
},
/*!
* jQuery UI Form Reset Mixin 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.ui.formResetMixin = {
_formResetHandler: function () {
var e = x(this);
setTimeout(function () {
var t = e.data("ui-form-reset-instances");
x.each(t, function () {
this.refresh()
})
})
}, _bindFormResetHandler: function () {
var t;
this.form = this.element._form(), this.form.length && ((t = this.form.data("ui-form-reset-instances") || []).length || this.form.on("reset.ui-form-reset", this._formResetHandler), t.push(this), this.form.data("ui-form-reset-instances", t))
}, _unbindFormResetHandler: function () {
var t;
this.form.length && ((t = this.form.data("ui-form-reset-instances")).splice(x.inArray(this, t), 1), t.length ? this.form.data("ui-form-reset-instances", t) : this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset"))
}
}, x.ui.ie = !!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),
/*!
* jQuery UI Support for jQuery core 1.8.x and newer 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*
*/
x.expr.pseudos || (x.expr.pseudos = x.expr[":"]), x.uniqueSort || (x.uniqueSort = x.unique), x.escapeSelector || (e = /([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g, i = function (t, e) {
return e ? "\0" === t ? "�" : t.slice(0, -1) + "\\" + t.charCodeAt(t.length - 1).toString(16) + " " : "\\" + t
}, x.escapeSelector = function (t) {
return (t + "").replace(e, i)
}), x.fn.even && x.fn.odd || x.fn.extend({
even: function () {
return this.filter(function (t) {
return t % 2 == 0
})
}, odd: function () {
return this.filter(function (t) {
return t % 2 == 1
})
}
}),
/*!
* jQuery UI Keycode 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.ui.keyCode = {
BACKSPACE: 8,
COMMA: 188,
DELETE: 46,
DOWN: 40,
END: 35,
ENTER: 13,
ESCAPE: 27,
HOME: 36,
LEFT: 37,
PAGE_DOWN: 34,
PAGE_UP: 33,
PERIOD: 190,
RIGHT: 39,
SPACE: 32,
TAB: 9,
UP: 38
},
/*!
* jQuery UI Labels 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.fn.labels = function () {
var t, e, i;
return this.length ? this[0].labels && this[0].labels.length ? this.pushStack(this[0].labels) : (e = this.eq(0).parents("label"), (t = this.attr("id")) && (i = (i = this.eq(0).parents().last()).add((i.length ? i : this).siblings()), t = "label[for='" + x.escapeSelector(t) + "']", e = e.add(i.find(t).addBack(t))), this.pushStack(e)) : this.pushStack([])
}, x.ui.plugin = {
add: function (t, e, i) {
var n, o = x.ui[t].prototype;
for (n in i) o.plugins[n] = o.plugins[n] || [], o.plugins[n].push([e, i[n]])
}, call: function (t, e, i, n) {
var o, s = t.plugins[e];
if (s && (n || t.element[0].parentNode && 11 !== t.element[0].parentNode.nodeType)) for (o = 0; o < s.length; o++) t.options[s[o][0]] && s[o][1].apply(t.element, i)
}
},
/*!
* jQuery UI Position 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*
* http://api.jqueryui.com/position/
*/
W = Math.max, C = Math.abs, o = /left|center|right/, s = /top|center|bottom/, r = /[\+\-]\d+(\.[\d]+)?%?/, l = /^\w+/, a = /%$/, h = x.fn.position, x.position = {
scrollbarWidth: function () {
var t, e, i;
return void 0 !== n ? n : (i = (e = x("
")).children()[0], x("body").append(e), t = i.offsetWidth, e.css("overflow", "scroll"), t === (i = i.offsetWidth) && (i = e[0].clientWidth), e.remove(), n = t - i)
}, getScrollInfo: function (t) {
var e = t.isWindow || t.isDocument ? "" : t.element.css("overflow-x"),
i = t.isWindow || t.isDocument ? "" : t.element.css("overflow-y"),
e = "scroll" === e || "auto" === e && t.width < t.element[0].scrollWidth;
return {
width: "scroll" === i || "auto" === i && t.height < t.element[0].scrollHeight ? x.position.scrollbarWidth() : 0,
height: e ? x.position.scrollbarWidth() : 0
}
}, getWithinInfo: function (t) {
var e = x(t || window), i = N(e[0]), n = !!e[0] && 9 === e[0].nodeType;
return {
element: e,
isWindow: i,
isDocument: n,
offset: !i && !n ? x(t).offset() : {left: 0, top: 0},
scrollLeft: e.scrollLeft(),
scrollTop: e.scrollTop(),
width: e.outerWidth(),
height: e.outerHeight()
}
}
}, x.fn.position = function (f) {
var c, d, p, g, m, v, y, w, b, _, t, e;
return f && f.of ? (v = "string" == typeof (f = x.extend({}, f)).of ? x(document).find(f.of) : x(f.of), y = x.position.getWithinInfo(f.within), w = x.position.getScrollInfo(y), b = (f.collision || "flip").split(" "), _ = {}, e = 9 === (e = (t = v)[0]).nodeType ? {
width: t.width(),
height: t.height(),
offset: {top: 0, left: 0}
} : N(e) ? {
width: t.width(),
height: t.height(),
offset: {top: t.scrollTop(), left: t.scrollLeft()}
} : e.preventDefault ? {width: 0, height: 0, offset: {top: e.pageY, left: e.pageX}} : {
width: t.outerWidth(),
height: t.outerHeight(),
offset: t.offset()
}, v[0].preventDefault && (f.at = "left top"), d = e.width, p = e.height, m = x.extend({}, g = e.offset), x.each(["my", "at"], function () {
var t, e, i = (f[this] || "").split(" ");
(i = 1 === i.length ? o.test(i[0]) ? i.concat(["center"]) : s.test(i[0]) ? ["center"].concat(i) : ["center", "center"] : i)[0] = o.test(i[0]) ? i[0] : "center", i[1] = s.test(i[1]) ? i[1] : "center", t = r.exec(i[0]), e = r.exec(i[1]), _[this] = [t ? t[0] : 0, e ? e[0] : 0], f[this] = [l.exec(i[0])[0], l.exec(i[1])[0]]
}), 1 === b.length && (b[1] = b[0]), "right" === f.at[0] ? m.left += d : "center" === f.at[0] && (m.left += d / 2), "bottom" === f.at[1] ? m.top += p : "center" === f.at[1] && (m.top += p / 2), c = E(_.at, d, p), m.left += c[0], m.top += c[1], this.each(function () {
var i, t, r = x(this), l = r.outerWidth(), a = r.outerHeight(), e = L(this, "marginLeft"),
n = L(this, "marginTop"), o = l + e + L(this, "marginRight") + w.width,
s = a + n + L(this, "marginBottom") + w.height, h = x.extend({}, m),
u = E(_.my, r.outerWidth(), r.outerHeight());
"right" === f.my[0] ? h.left -= l : "center" === f.my[0] && (h.left -= l / 2), "bottom" === f.my[1] ? h.top -= a : "center" === f.my[1] && (h.top -= a / 2), h.left += u[0], h.top += u[1], i = {
marginLeft: e,
marginTop: n
}, x.each(["left", "top"], function (t, e) {
x.ui.position[b[t]] && x.ui.position[b[t]][e](h, {
targetWidth: d,
targetHeight: p,
elemWidth: l,
elemHeight: a,
collisionPosition: i,
collisionWidth: o,
collisionHeight: s,
offset: [c[0] + u[0], c[1] + u[1]],
my: f.my,
at: f.at,
within: y,
elem: r
})
}), f.using && (t = function (t) {
var e = g.left - h.left, i = e + d - l, n = g.top - h.top, o = n + p - a, s = {
target: {element: v, left: g.left, top: g.top, width: d, height: p},
element: {element: r, left: h.left, top: h.top, width: l, height: a},
horizontal: i < 0 ? "left" : 0 < e ? "right" : "center",
vertical: o < 0 ? "top" : 0 < n ? "bottom" : "middle"
};
d < l && C(e + i) < d && (s.horizontal = "center"), p < a && C(n + o) < p && (s.vertical = "middle"), W(C(e), C(i)) > W(C(n), C(o)) ? s.important = "horizontal" : s.important = "vertical", f.using.call(this, t, s)
}), r.offset(x.extend(h, {using: t}))
})) : h.apply(this, arguments)
}, x.ui.position = {
fit: {
left: function (t, e) {
var i, n = e.within, o = n.isWindow ? n.scrollLeft : n.offset.left, n = n.width,
s = t.left - e.collisionPosition.marginLeft, r = o - s, l = s + e.collisionWidth - n - o;
e.collisionWidth > n ? 0 < r && l <= 0 ? (i = t.left + r + e.collisionWidth - n - o, t.left += r - i) : t.left = !(0 < l && r <= 0) && l < r ? o + n - e.collisionWidth : o : 0 < r ? t.left += r : 0 < l ? t.left -= l : t.left = W(t.left - s, t.left)
}, top: function (t, e) {
var i, n = e.within, n = n.isWindow ? n.scrollTop : n.offset.top, o = e.within.height,
s = t.top - e.collisionPosition.marginTop, r = n - s, l = s + e.collisionHeight - o - n;
e.collisionHeight > o ? 0 < r && l <= 0 ? (i = t.top + r + e.collisionHeight - o - n, t.top += r - i) : t.top = !(0 < l && r <= 0) && l < r ? n + o - e.collisionHeight : n : 0 < r ? t.top += r : 0 < l ? t.top -= l : t.top = W(t.top - s, t.top)
}
}, flip: {
left: function (t, e) {
var i = e.within, n = i.offset.left + i.scrollLeft, o = i.width,
i = i.isWindow ? i.scrollLeft : i.offset.left, s = t.left - e.collisionPosition.marginLeft,
r = s - i, s = s + e.collisionWidth - o - i,
l = "left" === e.my[0] ? -e.elemWidth : "right" === e.my[0] ? e.elemWidth : 0,
a = "left" === e.at[0] ? e.targetWidth : "right" === e.at[0] ? -e.targetWidth : 0,
h = -2 * e.offset[0];
r < 0 ? ((o = t.left + l + a + h + e.collisionWidth - o - n) < 0 || o < C(r)) && (t.left += l + a + h) : 0 < s && (0 < (n = t.left - e.collisionPosition.marginLeft + l + a + h - i) || C(n) < s) && (t.left += l + a + h)
}, top: function (t, e) {
var i = e.within, n = i.offset.top + i.scrollTop, o = i.height,
i = i.isWindow ? i.scrollTop : i.offset.top, s = t.top - e.collisionPosition.marginTop, r = s - i,
s = s + e.collisionHeight - o - i,
l = "top" === e.my[1] ? -e.elemHeight : "bottom" === e.my[1] ? e.elemHeight : 0,
a = "top" === e.at[1] ? e.targetHeight : "bottom" === e.at[1] ? -e.targetHeight : 0,
h = -2 * e.offset[1];
r < 0 ? ((o = t.top + l + a + h + e.collisionHeight - o - n) < 0 || o < C(r)) && (t.top += l + a + h) : 0 < s && (0 < (n = t.top - e.collisionPosition.marginTop + l + a + h - i) || C(n) < s) && (t.top += l + a + h)
}
}, flipfit: {
left: function () {
x.ui.position.flip.left.apply(this, arguments), x.ui.position.fit.left.apply(this, arguments)
}, top: function () {
x.ui.position.flip.top.apply(this, arguments), x.ui.position.fit.top.apply(this, arguments)
}
}
}, x.ui.safeActiveElement = function (e) {
var i;
try {
i = e.activeElement
} catch (t) {
i = e.body
}
return i = (i = i || e.body).nodeName ? i : e.body
}, x.ui.safeBlur = function (t) {
t && "body" !== t.nodeName.toLowerCase() && x(t).trigger("blur")
},
/*!
* jQuery UI Scroll Parent 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.fn.scrollParent = function (t) {
var e = this.css("position"), i = "absolute" === e, n = t ? /(auto|scroll|hidden)/ : /(auto|scroll)/,
t = this.parents().filter(function () {
var t = x(this);
return (!i || "static" !== t.css("position")) && n.test(t.css("overflow") + t.css("overflow-y") + t.css("overflow-x"))
}).eq(0);
return "fixed" !== e && t.length ? t : x(this[0].ownerDocument || document)
},
/*!
* jQuery UI Tabbable 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.extend(x.expr.pseudos, {
tabbable: function (t) {
var e = x.attr(t, "tabindex"), i = null != e;
return (!i || 0 <= e) && x.ui.focusable(t, i)
}
}),
/*!
* jQuery UI Unique ID 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
x.fn.extend({
uniqueId: (u = 0, function () {
return this.each(function () {
this.id || (this.id = "ui-id-" + ++u)
})
}), removeUniqueId: function () {
return this.each(function () {
/^ui-id-\d+$/.test(this.id) && x(this).removeAttr("id")
})
}
});
/*!
* jQuery UI Widget 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
var f, c = 0, d = Array.prototype.hasOwnProperty, p = Array.prototype.slice;
x.cleanData = (f = x.cleanData, function (t) {
for (var e, i, n = 0; null != (i = t[n]); n++) (e = x._data(i, "events")) && e.remove && x(i).triggerHandler("remove");
f(t)
}), x.widget = function (t, i, e) {
var n, o, s, r = {}, l = t.split(".")[0], a = l + "-" + (t = t.split(".")[1]);
return e || (e = i, i = x.Widget), Array.isArray(e) && (e = x.extend.apply(null, [{}].concat(e))), x.expr.pseudos[a.toLowerCase()] = function (t) {
return !!x.data(t, a)
}, x[l] = x[l] || {}, n = x[l][t], o = x[l][t] = function (t, e) {
if (!this || !this._createWidget) return new o(t, e);
arguments.length && this._createWidget(t, e)
}, x.extend(o, n, {
version: e.version,
_proto: x.extend({}, e),
_childConstructors: []
}), (s = new i).options = x.widget.extend({}, s.options), x.each(e, function (e, n) {
function o() {
return i.prototype[e].apply(this, arguments)
}
function s(t) {
return i.prototype[e].apply(this, t)
}
r[e] = "function" != typeof n ? n : function () {
var t, e = this._super, i = this._superApply;
return this._super = o, this._superApply = s, t = n.apply(this, arguments), this._super = e, this._superApply = i, t
}
}), o.prototype = x.widget.extend(s, {widgetEventPrefix: n && s.widgetEventPrefix || t}, r, {
constructor: o,
namespace: l,
widgetName: t,
widgetFullName: a
}), n ? (x.each(n._childConstructors, function (t, e) {
var i = e.prototype;
x.widget(i.namespace + "." + i.widgetName, o, e._proto)
}), delete n._childConstructors) : i._childConstructors.push(o), x.widget.bridge(t, o), o
}, x.widget.extend = function (t) {
for (var e, i, n = p.call(arguments, 1), o = 0, s = n.length; o < s; o++) for (e in n[o]) i = n[o][e], d.call(n[o], e) && void 0 !== i && (x.isPlainObject(i) ? t[e] = x.isPlainObject(t[e]) ? x.widget.extend({}, t[e], i) : x.widget.extend({}, i) : t[e] = i);
return t
}, x.widget.bridge = function (s, e) {
var r = e.prototype.widgetFullName || s;
x.fn[s] = function (i) {
var t = "string" == typeof i, n = p.call(arguments, 1), o = this;
return t ? this.length || "instance" !== i ? this.each(function () {
var t, e = x.data(this, r);
return "instance" === i ? (o = e, !1) : e ? "function" != typeof e[i] || "_" === i.charAt(0) ? x.error("no such method '" + i + "' for " + s + " widget instance") : (t = e[i].apply(e, n)) !== e && void 0 !== t ? (o = t && t.jquery ? o.pushStack(t.get()) : t, !1) : void 0 : x.error("cannot call methods on " + s + " prior to initialization; attempted to call method '" + i + "'")
}) : o = void 0 : (n.length && (i = x.widget.extend.apply(null, [i].concat(n))), this.each(function () {
var t = x.data(this, r);
t ? (t.option(i || {}), t._init && t._init()) : x.data(this, r, new e(i, this))
})), o
}
}, x.Widget = function () {
}, x.Widget._childConstructors = [], x.Widget.prototype = {
widgetName: "widget",
widgetEventPrefix: "",
defaultElement: "
",
options: {classes: {}, disabled: !1, create: null},
_createWidget: function (t, e) {
e = x(e || this.defaultElement || this)[0], this.element = x(e), this.uuid = c++, this.eventNamespace = "." + this.widgetName + this.uuid, this.bindings = x(), this.hoverable = x(), this.focusable = x(), this.classesElementLookup = {}, e !== this && (x.data(e, this.widgetFullName, this), this._on(!0, this.element, {
remove: function (t) {
t.target === e && this.destroy()
}
}), this.document = x(e.style ? e.ownerDocument : e.document || e), this.window = x(this.document[0].defaultView || this.document[0].parentWindow)), this.options = x.widget.extend({}, this.options, this._getCreateOptions(), t), this._create(), this.options.disabled && this._setOptionDisabled(this.options.disabled), this._trigger("create", null, this._getCreateEventData()), this._init()
},
_getCreateOptions: function () {
return {}
},
_getCreateEventData: x.noop,
_create: x.noop,
_init: x.noop,
destroy: function () {
var i = this;
this._destroy(), x.each(this.classesElementLookup, function (t, e) {
i._removeClass(e, t)
}), this.element.off(this.eventNamespace).removeData(this.widgetFullName), this.widget().off(this.eventNamespace).removeAttr("aria-disabled"), this.bindings.off(this.eventNamespace)
},
_destroy: x.noop,
widget: function () {
return this.element
},
option: function (t, e) {
var i, n, o, s = t;
if (0 === arguments.length) return x.widget.extend({}, this.options);
if ("string" == typeof t) if (s = {}, t = (i = t.split(".")).shift(), i.length) {
for (n = s[t] = x.widget.extend({}, this.options[t]), o = 0; o < i.length - 1; o++) n[i[o]] = n[i[o]] || {}, n = n[i[o]];
if (t = i.pop(), 1 === arguments.length) return void 0 === n[t] ? null : n[t];
n[t] = e
} else {
if (1 === arguments.length) return void 0 === this.options[t] ? null : this.options[t];
s[t] = e
}
return this._setOptions(s), this
},
_setOptions: function (t) {
for (var e in t) this._setOption(e, t[e]);
return this
},
_setOption: function (t, e) {
return "classes" === t && this._setOptionClasses(e), this.options[t] = e, "disabled" === t && this._setOptionDisabled(e), this
},
_setOptionClasses: function (t) {
var e, i, n;
for (e in t) n = this.classesElementLookup[e], t[e] !== this.options.classes[e] && n && n.length && (i = x(n.get()), this._removeClass(n, e), i.addClass(this._classes({
element: i,
keys: e,
classes: t,
add: !0
})))
},
_setOptionDisabled: function (t) {
this._toggleClass(this.widget(), this.widgetFullName + "-disabled", null, !!t), t && (this._removeClass(this.hoverable, null, "ui-state-hover"), this._removeClass(this.focusable, null, "ui-state-focus"))
},
enable: function () {
return this._setOptions({disabled: !1})
},
disable: function () {
return this._setOptions({disabled: !0})
},
_classes: function (o) {
var s = [], r = this;
function t(t, e) {
for (var i, n = 0; n < t.length; n++) i = r.classesElementLookup[t[n]] || x(), i = o.add ? (function () {
var i = [];
o.element.each(function (t, e) {
x.map(r.classesElementLookup, function (t) {
return t
}).some(function (t) {
return t.is(e)
}) || i.push(e)
}), r._on(x(i), {remove: "_untrackClassesElement"})
}(), x(x.uniqueSort(i.get().concat(o.element.get())))) : x(i.not(o.element).get()), r.classesElementLookup[t[n]] = i, s.push(t[n]), e && o.classes[t[n]] && s.push(o.classes[t[n]])
}
return (o = x.extend({
element: this.element,
classes: this.options.classes || {}
}, o)).keys && t(o.keys.match(/\S+/g) || [], !0), o.extra && t(o.extra.match(/\S+/g) || []), s.join(" ")
},
_untrackClassesElement: function (i) {
var n = this;
x.each(n.classesElementLookup, function (t, e) {
-1 !== x.inArray(i.target, e) && (n.classesElementLookup[t] = x(e.not(i.target).get()))
}), this._off(x(i.target))
},
_removeClass: function (t, e, i) {
return this._toggleClass(t, e, i, !1)
},
_addClass: function (t, e, i) {
return this._toggleClass(t, e, i, !0)
},
_toggleClass: function (t, e, i, n) {
var o = "string" == typeof t || null === t, e = {
extra: o ? e : i,
keys: o ? t : e,
element: o ? this.element : t,
add: n = "boolean" == typeof n ? n : i
};
return e.element.toggleClass(this._classes(e), n), this
},
_on: function (o, s, t) {
var r, l = this;
"boolean" != typeof o && (t = s, s = o, o = !1), t ? (s = r = x(s), this.bindings = this.bindings.add(s)) : (t = s, s = this.element, r = this.widget()), x.each(t, function (t, e) {
function i() {
if (o || !0 !== l.options.disabled && !x(this).hasClass("ui-state-disabled")) return ("string" == typeof e ? l[e] : e).apply(l, arguments)
}
"string" != typeof e && (i.guid = e.guid = e.guid || i.guid || x.guid++);
var t = t.match(/^([\w:-]*)\s*(.*)$/), n = t[1] + l.eventNamespace, t = t[2];
t ? r.on(n, t, i) : s.on(n, i)
})
},
_off: function (t, e) {
e = (e || "").split(" ").join(this.eventNamespace + " ") + this.eventNamespace, t.off(e), this.bindings = x(this.bindings.not(t).get()), this.focusable = x(this.focusable.not(t).get()), this.hoverable = x(this.hoverable.not(t).get())
},
_delay: function (t, e) {
var i = this;
return setTimeout(function () {
return ("string" == typeof t ? i[t] : t).apply(i, arguments)
}, e || 0)
},
_hoverable: function (t) {
this.hoverable = this.hoverable.add(t), this._on(t, {
mouseenter: function (t) {
this._addClass(x(t.currentTarget), null, "ui-state-hover")
}, mouseleave: function (t) {
this._removeClass(x(t.currentTarget), null, "ui-state-hover")
}
})
},
_focusable: function (t) {
this.focusable = this.focusable.add(t), this._on(t, {
focusin: function (t) {
this._addClass(x(t.currentTarget), null, "ui-state-focus")
}, focusout: function (t) {
this._removeClass(x(t.currentTarget), null, "ui-state-focus")
}
})
},
_trigger: function (t, e, i) {
var n, o, s = this.options[t];
if (i = i || {}, (e = x.Event(e)).type = (t === this.widgetEventPrefix ? t : this.widgetEventPrefix + t).toLowerCase(), e.target = this.element[0], o = e.originalEvent) for (n in o) n in e || (e[n] = o[n]);
return this.element.trigger(e, i), !("function" == typeof s && !1 === s.apply(this.element[0], [e].concat(i)) || e.isDefaultPrevented())
}
}, x.each({show: "fadeIn", hide: "fadeOut"}, function (s, r) {
x.Widget.prototype["_" + s] = function (e, t, i) {
var n,
o = (t = "string" == typeof t ? {effect: t} : t) ? !0 !== t && "number" != typeof t && t.effect || r : s;
"number" == typeof (t = t || {}) ? t = {duration: t} : !0 === t && (t = {}), n = !x.isEmptyObject(t), t.complete = i, t.delay && e.delay(t.delay), n && x.effects && x.effects.effect[o] ? e[s](t) : o !== s && e[o] ? e[o](t.duration, t.easing, i) : e.queue(function (t) {
x(this)[s](), i && i.call(e[0]), t()
})
}
})
});
/*!
* jQuery UI Mouse 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
!function (e) {
"use strict";
"function" == typeof define && define.amd ? define(["jquery", "./core"], e) : e(jQuery)
}(function (o) {
"use strict";
var n = !1;
return o(document).on("mouseup", function () {
n = !1
}), o.widget("ui.mouse", {
version: "1.13.2",
options: {cancel: "input, textarea, button, select, option", distance: 1, delay: 0},
_mouseInit: function () {
var t = this;
this.element.on("mousedown." + this.widgetName, function (e) {
return t._mouseDown(e)
}).on("click." + this.widgetName, function (e) {
if (!0 === o.data(e.target, t.widgetName + ".preventClickEvent")) return o.removeData(e.target, t.widgetName + ".preventClickEvent"), e.stopImmediatePropagation(), !1
}), this.started = !1
},
_mouseDestroy: function () {
this.element.off("." + this.widgetName), this._mouseMoveDelegate && this.document.off("mousemove." + this.widgetName, this._mouseMoveDelegate).off("mouseup." + this.widgetName, this._mouseUpDelegate)
},
_mouseDown: function (e) {
var t, s, i;
if (!n) return this._mouseMoved = !1, this._mouseStarted && this._mouseUp(e), s = 1 === (this._mouseDownEvent = e).which, i = !("string" != typeof (t = this).options.cancel || !e.target.nodeName) && o(e.target).closest(this.options.cancel).length, s && !i && this._mouseCapture(e) && (this.mouseDelayMet = !this.options.delay, this.mouseDelayMet || (this._mouseDelayTimer = setTimeout(function () {
t.mouseDelayMet = !0
}, this.options.delay)), this._mouseDistanceMet(e) && this._mouseDelayMet(e) && (this._mouseStarted = !1 !== this._mouseStart(e), !this._mouseStarted) ? e.preventDefault() : (!0 === o.data(e.target, this.widgetName + ".preventClickEvent") && o.removeData(e.target, this.widgetName + ".preventClickEvent"), this._mouseMoveDelegate = function (e) {
return t._mouseMove(e)
}, this._mouseUpDelegate = function (e) {
return t._mouseUp(e)
}, this.document.on("mousemove." + this.widgetName, this._mouseMoveDelegate).on("mouseup." + this.widgetName, this._mouseUpDelegate), e.preventDefault(), n = !0)), !0
},
_mouseMove: function (e) {
if (this._mouseMoved) {
if (o.ui.ie && (!document.documentMode || document.documentMode < 9) && !e.button) return this._mouseUp(e);
if (!e.which) if (e.originalEvent.altKey || e.originalEvent.ctrlKey || e.originalEvent.metaKey || e.originalEvent.shiftKey) this.ignoreMissingWhich = !0; else if (!this.ignoreMissingWhich) return this._mouseUp(e)
}
return (e.which || e.button) && (this._mouseMoved = !0), this._mouseStarted ? (this._mouseDrag(e), e.preventDefault()) : (this._mouseDistanceMet(e) && this._mouseDelayMet(e) && (this._mouseStarted = !1 !== this._mouseStart(this._mouseDownEvent, e), this._mouseStarted ? this._mouseDrag(e) : this._mouseUp(e)), !this._mouseStarted)
},
_mouseUp: function (e) {
this.document.off("mousemove." + this.widgetName, this._mouseMoveDelegate).off("mouseup." + this.widgetName, this._mouseUpDelegate), this._mouseStarted && (this._mouseStarted = !1, e.target === this._mouseDownEvent.target && o.data(e.target, this.widgetName + ".preventClickEvent", !0), this._mouseStop(e)), this._mouseDelayTimer && (clearTimeout(this._mouseDelayTimer), delete this._mouseDelayTimer), this.ignoreMissingWhich = !1, n = !1, e.preventDefault()
},
_mouseDistanceMet: function (e) {
return Math.max(Math.abs(this._mouseDownEvent.pageX - e.pageX), Math.abs(this._mouseDownEvent.pageY - e.pageY)) >= this.options.distance
},
_mouseDelayMet: function () {
return this.mouseDelayMet
},
_mouseStart: function () {
},
_mouseDrag: function () {
},
_mouseStop: function () {
},
_mouseCapture: function () {
return !0
}
})
});
/*!
* jQuery UI Slider 1.13.2
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*/
!function (e) {
"use strict";
"function" == typeof define && define.amd ? define(["jquery", "./mouse", "./core"], e) : e(jQuery)
}(function (o) {
"use strict";
return o.widget("ui.slider", o.ui.mouse, {
version: "1.13.2",
widgetEventPrefix: "slide",
options: {
animate: !1,
classes: {
"ui-slider": "ui-corner-all",
"ui-slider-handle": "ui-corner-all",
"ui-slider-range": "ui-corner-all ui-widget-header"
},
distance: 0,
max: 100,
min: 0,
orientation: "horizontal",
range: !1,
step: 1,
value: 0,
values: null,
change: null,
slide: null,
start: null,
stop: null
},
numPages: 5,
_create: function () {
this._keySliding = !1, this._mouseSliding = !1, this._animateOff = !0, this._handleIndex = null, this._detectOrientation(), this._mouseInit(), this._calculateNewMax(), this._addClass("ui-slider ui-slider-" + this.orientation, "ui-widget ui-widget-content"), this._refresh(), this._animateOff = !1
},
_refresh: function () {
this._createRange(), this._createHandles(), this._setupEvents(), this._refreshValue()
},
_createHandles: function () {
var e, t = this.options, i = this.element.find(".ui-slider-handle"), s = [],
a = t.values && t.values.length || 1;
for (i.length > a && (i.slice(a).remove(), i = i.slice(0, a)), e = i.length; e < a; e++) s.push("");
this.handles = i.add(o(s.join("")).appendTo(this.element)), this._addClass(this.handles, "ui-slider-handle", "ui-state-default"), this.handle = this.handles.eq(0), this.handles.each(function (e) {
o(this).data("ui-slider-handle-index", e).attr("tabIndex", 0)
})
},
_createRange: function () {
var e = this.options;
e.range ? (!0 === e.range && (e.values ? e.values.length && 2 !== e.values.length ? e.values = [e.values[0], e.values[0]] : Array.isArray(e.values) && (e.values = e.values.slice(0)) : e.values = [this._valueMin(), this._valueMin()]), this.range && this.range.length ? (this._removeClass(this.range, "ui-slider-range-min ui-slider-range-max"), this.range.css({
left: "",
bottom: ""
})) : (this.range = o("
").appendTo(this.element), this._addClass(this.range, "ui-slider-range")), "min" !== e.range && "max" !== e.range || this._addClass(this.range, "ui-slider-range-" + e.range)) : (this.range && this.range.remove(), this.range = null)
},
_setupEvents: function () {
this._off(this.handles), this._on(this.handles, this._handleEvents), this._hoverable(this.handles), this._focusable(this.handles)
},
_destroy: function () {
this.handles.remove(), this.range && this.range.remove(), this._mouseDestroy()
},
_mouseCapture: function (e) {
var i, s, a, n, t, h, l = this, u = this.options;
return !u.disabled && (this.elementSize = {
width: this.element.outerWidth(),
height: this.element.outerHeight()
}, this.elementOffset = this.element.offset(), t = {
x: e.pageX,
y: e.pageY
}, i = this._normValueFromMouse(t), s = this._valueMax() - this._valueMin() + 1, this.handles.each(function (e) {
var t = Math.abs(i - l.values(e));
(t < s || s === t && (e === l._lastChangedValue || l.values(e) === u.min)) && (s = t, a = o(this), n = e)
}), !1 !== this._start(e, n)) && (this._mouseSliding = !0, this._handleIndex = n, this._addClass(a, null, "ui-state-active"), a.trigger("focus"), t = a.offset(), h = !o(e.target).parents().addBack().is(".ui-slider-handle"), this._clickOffset = h ? {
left: 0,
top: 0
} : {
left: e.pageX - t.left - a.width() / 2,
top: e.pageY - t.top - a.height() / 2 - (parseInt(a.css("borderTopWidth"), 10) || 0) - (parseInt(a.css("borderBottomWidth"), 10) || 0) + (parseInt(a.css("marginTop"), 10) || 0)
}, this.handles.hasClass("ui-state-hover") || this._slide(e, n, i), this._animateOff = !0)
},
_mouseStart: function () {
return !0
},
_mouseDrag: function (e) {
var t = {x: e.pageX, y: e.pageY}, t = this._normValueFromMouse(t);
return this._slide(e, this._handleIndex, t), !1
},
_mouseStop: function (e) {
return this._removeClass(this.handles, null, "ui-state-active"), this._mouseSliding = !1, this._stop(e, this._handleIndex), this._change(e, this._handleIndex), this._handleIndex = null, this._clickOffset = null, this._animateOff = !1
},
_detectOrientation: function () {
this.orientation = "vertical" === this.options.orientation ? "vertical" : "horizontal"
},
_normValueFromMouse: function (e) {
var t,
e = "horizontal" === this.orientation ? (t = this.elementSize.width, e.x - this.elementOffset.left - (this._clickOffset ? this._clickOffset.left : 0)) : (t = this.elementSize.height, e.y - this.elementOffset.top - (this._clickOffset ? this._clickOffset.top : 0)),
e = e / t;
return (e = 1 < e ? 1 : e) < 0 && (e = 0), "vertical" === this.orientation && (e = 1 - e), t = this._valueMax() - this._valueMin(), e = this._valueMin() + e * t, this._trimAlignValue(e)
},
_uiHash: function (e, t, i) {
var s = {handle: this.handles[e], handleIndex: e, value: void 0 !== t ? t : this.value()};
return this._hasMultipleValues() && (s.value = void 0 !== t ? t : this.values(e), s.values = i || this.values()), s
},
_hasMultipleValues: function () {
return this.options.values && this.options.values.length
},
_start: function (e, t) {
return this._trigger("start", e, this._uiHash(t))
},
_slide: function (e, t, i) {
var s, a = this.value(), n = this.values();
this._hasMultipleValues() && (s = this.values(t ? 0 : 1), a = this.values(t), 2 === this.options.values.length && !0 === this.options.range && (i = 0 === t ? Math.min(s, i) : Math.max(s, i)), n[t] = i), i !== a && !1 !== this._trigger("slide", e, this._uiHash(t, i, n)) && (this._hasMultipleValues() ? this.values(t, i) : this.value(i))
},
_stop: function (e, t) {
this._trigger("stop", e, this._uiHash(t))
},
_change: function (e, t) {
this._keySliding || this._mouseSliding || (this._lastChangedValue = t, this._trigger("change", e, this._uiHash(t)))
},
value: function (e) {
if (!arguments.length) return this._value();
this.options.value = this._trimAlignValue(e), this._refreshValue(), this._change(null, 0)
},
values: function (e, t) {
var i, s, a;
if (1 < arguments.length) this.options.values[e] = this._trimAlignValue(t), this._refreshValue(), this._change(null, e); else {
if (!arguments.length) return this._values();
if (!Array.isArray(e)) return this._hasMultipleValues() ? this._values(e) : this.value();
for (i = this.options.values, s = e, a = 0; a < i.length; a += 1) i[a] = this._trimAlignValue(s[a]), this._change(null, a);
this._refreshValue()
}
},
_setOption: function (e, t) {
var i, s = 0;
switch ("range" === e && !0 === this.options.range && ("min" === t ? (this.options.value = this._values(0), this.options.values = null) : "max" === t && (this.options.value = this._values(this.options.values.length - 1), this.options.values = null)), Array.isArray(this.options.values) && (s = this.options.values.length), this._super(e, t), e) {
case"orientation":
this._detectOrientation(), this._removeClass("ui-slider-horizontal ui-slider-vertical")._addClass("ui-slider-" + this.orientation), this._refreshValue(), this.options.range && this._refreshRange(t), this.handles.css("horizontal" === t ? "bottom" : "left", "");
break;
case"value":
this._animateOff = !0, this._refreshValue(), this._change(null, 0), this._animateOff = !1;
break;
case"values":
for (this._animateOff = !0, this._refreshValue(), i = s - 1; 0 <= i; i--) this._change(null, i);
this._animateOff = !1;
break;
case"step":
case"min":
case"max":
this._animateOff = !0, this._calculateNewMax(), this._refreshValue(), this._animateOff = !1;
break;
case"range":
this._animateOff = !0, this._refresh(), this._animateOff = !1
}
},
_setOptionDisabled: function (e) {
this._super(e), this._toggleClass(null, "ui-state-disabled", !!e)
},
_value: function () {
var e = this.options.value;
return this._trimAlignValue(e)
},
_values: function (e) {
var t, i;
if (arguments.length) return e = this.options.values[e], this._trimAlignValue(e);
if (this._hasMultipleValues()) {
for (t = this.options.values.slice(), i = 0; i < t.length; i += 1) t[i] = this._trimAlignValue(t[i]);
return t
}
return []
},
_trimAlignValue: function (e) {
var t, i;
return e <= this._valueMin() ? this._valueMin() : e >= this._valueMax() ? this._valueMax() : (t = 0 < this.options.step ? this.options.step : 1, i = e - (e = (e - this._valueMin()) % t), 2 * Math.abs(e) >= t && (i += 0 < e ? t : -t), parseFloat(i.toFixed(5)))
},
_calculateNewMax: function () {
var e = this.options.max, t = this._valueMin(), i = this.options.step;
(e = Math.round((e - t) / i) * i + t) > this.options.max && (e -= i), this.max = parseFloat(e.toFixed(this._precision()))
},
_precision: function () {
var e = this._precisionOf(this.options.step);
return e = null !== this.options.min ? Math.max(e, this._precisionOf(this.options.min)) : e
},
_precisionOf: function (e) {
var e = e.toString(), t = e.indexOf(".");
return -1 === t ? 0 : e.length - t - 1
},
_valueMin: function () {
return this.options.min
},
_valueMax: function () {
return this.max
},
_refreshRange: function (e) {
"vertical" === e && this.range.css({width: "", left: ""}), "horizontal" === e && this.range.css({
height: "",
bottom: ""
})
},
_refreshValue: function () {
var t, i, e, s, a, n = this.options.range, h = this.options, l = this, u = !this._animateOff && h.animate,
r = {};
this._hasMultipleValues() ? this.handles.each(function (e) {
i = (l.values(e) - l._valueMin()) / (l._valueMax() - l._valueMin()) * 100, r["horizontal" === l.orientation ? "left" : "bottom"] = i + "%", o(this).stop(1, 1)[u ? "animate" : "css"](r, h.animate), !0 === l.options.range && ("horizontal" === l.orientation ? (0 === e && l.range.stop(1, 1)[u ? "animate" : "css"]({left: i + "%"}, h.animate), 1 === e && l.range[u ? "animate" : "css"]({width: i - t + "%"}, {
queue: !1,
duration: h.animate
})) : (0 === e && l.range.stop(1, 1)[u ? "animate" : "css"]({bottom: i + "%"}, h.animate), 1 === e && l.range[u ? "animate" : "css"]({height: i - t + "%"}, {
queue: !1,
duration: h.animate
}))), t = i
}) : (e = this.value(), s = this._valueMin(), a = this._valueMax(), i = a !== s ? (e - s) / (a - s) * 100 : 0, r["horizontal" === this.orientation ? "left" : "bottom"] = i + "%", this.handle.stop(1, 1)[u ? "animate" : "css"](r, h.animate), "min" === n && "horizontal" === this.orientation && this.range.stop(1, 1)[u ? "animate" : "css"]({width: i + "%"}, h.animate), "max" === n && "horizontal" === this.orientation && this.range.stop(1, 1)[u ? "animate" : "css"]({width: 100 - i + "%"}, h.animate), "min" === n && "vertical" === this.orientation && this.range.stop(1, 1)[u ? "animate" : "css"]({height: i + "%"}, h.animate), "max" === n && "vertical" === this.orientation && this.range.stop(1, 1)[u ? "animate" : "css"]({height: 100 - i + "%"}, h.animate))
},
_handleEvents: {
keydown: function (e) {
var t, i, s, a = o(e.target).data("ui-slider-handle-index");
switch (e.keyCode) {
case o.ui.keyCode.HOME:
case o.ui.keyCode.END:
case o.ui.keyCode.PAGE_UP:
case o.ui.keyCode.PAGE_DOWN:
case o.ui.keyCode.UP:
case o.ui.keyCode.RIGHT:
case o.ui.keyCode.DOWN:
case o.ui.keyCode.LEFT:
if (e.preventDefault(), this._keySliding || (this._keySliding = !0, this._addClass(o(e.target), null, "ui-state-active"), !1 !== this._start(e, a))) break;
return
}
switch (s = this.options.step, t = i = this._hasMultipleValues() ? this.values(a) : this.value(), e.keyCode) {
case o.ui.keyCode.HOME:
i = this._valueMin();
break;
case o.ui.keyCode.END:
i = this._valueMax();
break;
case o.ui.keyCode.PAGE_UP:
i = this._trimAlignValue(t + (this._valueMax() - this._valueMin()) / this.numPages);
break;
case o.ui.keyCode.PAGE_DOWN:
i = this._trimAlignValue(t - (this._valueMax() - this._valueMin()) / this.numPages);
break;
case o.ui.keyCode.UP:
case o.ui.keyCode.RIGHT:
if (t === this._valueMax()) return;
i = this._trimAlignValue(t + s);
break;
case o.ui.keyCode.DOWN:
case o.ui.keyCode.LEFT:
if (t === this._valueMin()) return;
i = this._trimAlignValue(t - s)
}
this._slide(e, a, i)
}, keyup: function (e) {
var t = o(e.target).data("ui-slider-handle-index");
this._keySliding && (this._keySliding = !1, this._stop(e, t), this._change(e, t), this._removeClass(o(e.target), null, "ui-state-active"))
}
}
})
});
/*!
* accounting.js v0.4.2
* Copyright 2014 Open Exchange Rates
*
* Freely distributable under the MIT license.
* Portions of accounting.js are inspired or borrowed from underscore.js
*
* Full details and documentation:
* http://openexchangerates.github.io/accounting.js/
*/
!function (n, r) {
var e = {
version: "0.4.1",
settings: {
currency: {symbol: "$", format: "%s%v", decimal: ".", thousand: ",", precision: 2, grouping: 3},
number: {precision: 0, grouping: 3, thousand: ",", decimal: "."}
}
}, t = Array.prototype.map, o = Array.isArray, a = Object.prototype.toString;
function i(n) {
return !!("" === n || n && n.charCodeAt && n.substr)
}
function u(n) {
return o ? o(n) : "[object Array]" === a.call(n)
}
function c(n) {
return n && "[object Object]" === a.call(n)
}
function s(n, r) {
var e;
for (e in n = n || {}, r = r || {}) r.hasOwnProperty(e) && null == n[e] && (n[e] = r[e]);
return n
}
function f(n, r, e) {
var o, a, i = [];
if (!n) return i;
if (t && n.map === t) return n.map(r, e);
for (o = 0, a = n.length; o < a; o++) i[o] = r.call(e, n[o], o, n);
return i
}
function p(n, r) {
return n = Math.round(Math.abs(n)), isNaN(n) ? r : n
}
function l(n) {
var r = e.settings.currency.format;
return "function" == typeof n && (n = n()), i(n) && n.match("%v") ? {
pos: n,
neg: n.replace("-", "").replace("%v", "-%v"),
zero: n
} : n && n.pos && n.pos.match("%v") ? n : i(r) ? e.settings.currency.format = {
pos: r,
neg: r.replace("%v", "-%v"),
zero: r
} : r
}
var m, d = e.unformat = e.parse = function (n, r) {
if (u(n)) return f(n, function (n) {
return d(n, r)
});
if ("number" == typeof (n = n || 0)) return n;
r = r || e.settings.number.decimal;
var t = new RegExp("[^0-9-" + r + "]", ["g"]),
o = parseFloat(("" + n).replace(/\((.*)\)/, "-$1").replace(t, "").replace(r, "."));
return isNaN(o) ? 0 : o
}, g = e.toFixed = function (n, r) {
r = p(r, e.settings.number.precision);
var t = Math.pow(10, r);
return (Math.round(e.unformat(n) * t) / t).toFixed(r)
}, h = e.formatNumber = e.format = function (n, r, t, o) {
if (u(n)) return f(n, function (n) {
return h(n, r, t, o)
});
n = d(n);
var a = s(c(r) ? r : {precision: r, thousand: t, decimal: o}, e.settings.number), i = p(a.precision),
l = n < 0 ? "-" : "", m = parseInt(g(Math.abs(n || 0), i), 10) + "", y = m.length > 3 ? m.length % 3 : 0;
return l + (y ? m.substr(0, y) + a.thousand : "") + m.substr(y).replace(/(\d{3})(?=\d)/g, "$1" + a.thousand) + (i ? a.decimal + g(Math.abs(n), i).split(".")[1] : "")
}, y = e.formatMoney = function (n, r, t, o, a, i) {
if (u(n)) return f(n, function (n) {
return y(n, r, t, o, a, i)
});
n = d(n);
var m = s(c(r) ? r : {symbol: r, precision: t, thousand: o, decimal: a, format: i}, e.settings.currency),
g = l(m.format);
return (n > 0 ? g.pos : n < 0 ? g.neg : g.zero).replace("%s", m.symbol).replace("%v", h(Math.abs(n), p(m.precision), m.thousand, m.decimal))
};
e.formatColumn = function (n, r, t, o, a, m) {
if (!n) return [];
var g = s(c(r) ? r : {symbol: r, precision: t, thousand: o, decimal: a, format: m}, e.settings.currency),
y = l(g.format), b = y.pos.indexOf("%s") < y.pos.indexOf("%v"), v = 0;
return f(f(n, function (n, r) {
if (u(n)) return e.formatColumn(n, g);
var t = ((n = d(n)) > 0 ? y.pos : n < 0 ? y.neg : y.zero).replace("%s", g.symbol).replace("%v", h(Math.abs(n), p(g.precision), g.thousand, g.decimal));
return t.length > v && (v = t.length), t
}), function (n, r) {
return i(n) && n.length < v ? b ? n.replace(g.symbol, g.symbol + new Array(v - n.length + 1).join(" ")) : new Array(v - n.length + 1).join(" ") + n : n
})
}, "undefined" != typeof exports ? ("undefined" != typeof module && module.exports && (exports = module.exports = e), exports.accounting = e) : "function" == typeof define && define.amd ? define([], function () {
return e
}) : (e.noConflict = (m = n.accounting, function () {
return n.accounting = m, e.noConflict = void 0, e
}), n.accounting = e)
}(this);
/*!
* jQuery Cookie Plugin v1.4.1
* https://github.com/carhartl/jquery-cookie
*
* Copyright 2013 Klaus Hartl
* Released under the MIT license
*/
!function (e) {
"function" == typeof define && define.amd ? define(["jquery"], e) : "object" == typeof exports ? e(require("jquery")) : e(jQuery)
}(function (e) {
var n = /\+/g;
function o(e) {
return r.raw ? e : encodeURIComponent(e)
}
function i(e, o) {
var i = r.raw ? e : function (e) {
0 === e.indexOf('"') && (e = e.slice(1, -1).replace(/\\"/g, '"').replace(/\\\\/g, "\\"));
try {
return e = decodeURIComponent(e.replace(n, " ")), r.json ? JSON.parse(e) : e
} catch (o) {
}
}(e);
return "function" == typeof o ? o(i) : i
}
var r = e.cookie = function (n, t, u) {
if (t !== undefined && "function" != typeof t) {
if ("number" == typeof (u = e.extend({}, r.defaults, u)).expires) {
var c = u.expires, f = u.expires = new Date;
f.setTime(+f + 864e5 * c)
}
return document.cookie = [o(n), "=", function (e) {
return o(r.json ? JSON.stringify(e) : String(e))
}(t), u.expires ? "; expires=" + u.expires.toUTCString() : "", u.path ? "; path=" + u.path : "", u.domain ? "; domain=" + u.domain : "", u.secure ? "; secure" : ""].join("")
}
for (var d, a = n ? undefined : {}, p = document.cookie ? document.cookie.split("; ") : [], s = 0, m = p.length; s < m; s++) {
var x = p[s].split("="), y = (d = x.shift(), r.raw ? d : decodeURIComponent(d)), k = x.join("=");
if (n && n === y) {
a = i(k, t);
break
}
n || (k = i(k)) === undefined || (a[y] = k)
}
return a
};
r.defaults = {}, e.removeCookie = function (n, o) {
return e.cookie(n) !== undefined && (e.cookie(n, "", e.extend({}, o, {expires: -1})), !e.cookie(n))
}
});
/**
* Theme functions file
*
* Contains handlers for navigation, accessibility, header sizing
* footer widgets and Featured Content slider
*
*/
(function ($) {
"use strict";
// Enable menu toggle for small screens.
$(document).ready(function () {
_wpbingo_count_view_product();
$('.newsletterpopup .close-popup').on("click", function () {
_wpbingo_HideNLPopup();
$.cookie("mafoil_lpopup", 1, {expires: 24 * 60 * 60 * 1000});
});
$('.newsletterpopup_overlay').on("click", function () {
_wpbingo_HideNLPopup();
$.cookie("mafoil_lpopup", 1, {expires: 24 * 60 * 60 * 1000});
});
});
/* Show/hide NewsLetter Popup */
$(window).load(function () {
_wpbingo_campbar();
_wpbingo_ShowNLPopup();
});
/* Function Show NewsLetter Popup */
function _wpbingo_ShowNLPopup() {
if ($('.newsletterpopup').length) {
var cookieValue = $.cookie("mafoil_lpopup");
if (cookieValue == 1) {
$('#newsletterpopup').removeClass('show');
} else {
$('#newsletterpopup').addClass('show');
setTimeout(function () {
$('#newsletterpopup').addClass('newsletterpopup-active');
}, 300);
setTimeout(function () {
$('#newsletterpopup').addClass('transition');
}, 600);
}
}
}
/* Function Hide NewsLetter Popup when click on button Close */
function _wpbingo_HideNLPopup() {
$('#newsletterpopup').removeClass('transition');
setTimeout(function () {
$('#newsletterpopup').removeClass('newsletterpopup-active');
}, 400);
setTimeout(function () {
$('#newsletterpopup').removeClass('show');
}, 700);
}
/* Function Count View Product */
function _wpbingo_count_view_product() {
if ($(".product-count-view").length > 0) {
var id_product = $(".product-count-view").data("id_product");
var min = $(".product-count-view").data("min") ? $(".product-count-view").data("min") : 30;
var max = $(".product-count-view").data("max") ? $(".product-count-view").data("max") : 40;
var timeout = $(".product-count-view").data("timeout") ? $(".product-count-view").data("timeout") : 10000;
var cookieValue = $.cookie("product_" + id_product);
if (cookieValue) {
$("span", ".product-count-view").html(cookieValue);
} else {
var rand = Math.round(Math.random() * (max - min)) + min;
$("span", ".product-count-view").html(rand);
$.cookie("product_" + id_product, rand, {expires: 24 * 60 * 60 * 1000});
}
setTimeout(function random() {
var auto = Math.round(Math.random() * (max - min)) + min;
$("span", ".product-count-view").html(auto);
setTimeout(random, timeout);
}, timeout);
}
}
function _wpbingo_campbar() {
$(".close-campbar").on("click", function () {
$('.header-campbar').slideUp();
$.cookie("mafoil_campbar", 1, {expires: 24 * 60 * 60 * 1000});
});
var cookieValue = $.cookie("mafoil_campbar");
if (cookieValue == 1) {
$('.header-campbar').hide();
} else {
$('.header-campbar').removeClass('hidden');
}
}
})(jQuery);
/* perfect-scrollbar v0.6.14 */
!function t(e, n, r) {
function o(i, s) {
if (!n[i]) {
if (!e[i]) {
var a = "function" == typeof require && require;
if (!s && a) return a(i, !0);
if (l) return l(i, !0);
var c = new Error("Cannot find module '" + i + "'");
throw c.code = "MODULE_NOT_FOUND", c
}
var u = n[i] = {exports: {}};
e[i][0].call(u.exports, function (t) {
var n = e[i][1][t];
return o(n ? n : t)
}, u, u.exports, t, e, n, r)
}
return n[i].exports
}
for (var l = "function" == typeof require && require, i = 0; i < r.length; i++) o(r[i]);
return o
}({
1: [function (t, e, n) {
"use strict";
function r(t) {
t.fn.perfectScrollbar = function (t) {
return this.each(function () {
if ("object" == typeof t || "undefined" == typeof t) {
var e = t;
l.get(this) || o.initialize(this, e)
} else {
var n = t;
"update" === n ? o.update(this) : "destroy" === n && o.destroy(this)
}
})
}
}
var o = t("../main"), l = t("../plugin/instances");
if ("function" == typeof define && define.amd) define(["jquery"], r); else {
var i = window.jQuery ? window.jQuery : window.$;
"undefined" != typeof i && r(i)
}
e.exports = r
}, {"../main": 7, "../plugin/instances": 18}],
2: [function (t, e, n) {
"use strict";
function r(t, e) {
var n = t.className.split(" ");
n.indexOf(e) < 0 && n.push(e), t.className = n.join(" ")
}
function o(t, e) {
var n = t.className.split(" "), r = n.indexOf(e);
r >= 0 && n.splice(r, 1), t.className = n.join(" ")
}
n.add = function (t, e) {
t.classList ? t.classList.add(e) : r(t, e)
}, n.remove = function (t, e) {
t.classList ? t.classList.remove(e) : o(t, e)
}, n.list = function (t) {
return t.classList ? Array.prototype.slice.apply(t.classList) : t.className.split(" ")
}
}, {}],
3: [function (t, e, n) {
"use strict";
function r(t, e) {
return window.getComputedStyle(t)[e]
}
function o(t, e, n) {
return "number" == typeof n && (n = n.toString() + "px"), t.style[e] = n, t
}
function l(t, e) {
for (var n in e) {
var r = e[n];
"number" == typeof r && (r = r.toString() + "px"), t.style[n] = r
}
return t
}
var i = {};
i.e = function (t, e) {
var n = document.createElement(t);
return n.className = e, n
}, i.appendTo = function (t, e) {
return e.appendChild(t), t
}, i.css = function (t, e, n) {
return "object" == typeof e ? l(t, e) : "undefined" == typeof n ? r(t, e) : o(t, e, n)
}, i.matches = function (t, e) {
return "undefined" != typeof t.matches ? t.matches(e) : "undefined" != typeof t.matchesSelector ? t.matchesSelector(e) : "undefined" != typeof t.webkitMatchesSelector ? t.webkitMatchesSelector(e) : "undefined" != typeof t.mozMatchesSelector ? t.mozMatchesSelector(e) : "undefined" != typeof t.msMatchesSelector ? t.msMatchesSelector(e) : void 0
}, i.remove = function (t) {
"undefined" != typeof t.remove ? t.remove() : t.parentNode && t.parentNode.removeChild(t)
}, i.queryChildren = function (t, e) {
return Array.prototype.filter.call(t.childNodes, function (t) {
return i.matches(t, e)
})
}, e.exports = i
}, {}],
4: [function (t, e, n) {
"use strict";
var r = function (t) {
this.element = t, this.events = {}
};
r.prototype.bind = function (t, e) {
"undefined" == typeof this.events[t] && (this.events[t] = []), this.events[t].push(e), this.element.addEventListener(t, e, !1)
}, r.prototype.unbind = function (t, e) {
var n = "undefined" != typeof e;
this.events[t] = this.events[t].filter(function (r) {
return !(!n || r === e) || (this.element.removeEventListener(t, r, !1), !1)
}, this)
}, r.prototype.unbindAll = function () {
for (var t in this.events) this.unbind(t)
};
var o = function () {
this.eventElements = []
};
o.prototype.eventElement = function (t) {
var e = this.eventElements.filter(function (e) {
return e.element === t
})[0];
return "undefined" == typeof e && (e = new r(t), this.eventElements.push(e)), e
}, o.prototype.bind = function (t, e, n) {
this.eventElement(t).bind(e, n)
}, o.prototype.unbind = function (t, e, n) {
this.eventElement(t).unbind(e, n)
}, o.prototype.unbindAll = function () {
for (var t = 0; t < this.eventElements.length; t++) this.eventElements[t].unbindAll()
}, o.prototype.once = function (t, e, n) {
var r = this.eventElement(t), o = function (t) {
r.unbind(e, o), n(t)
};
r.bind(e, o)
}, e.exports = o
}, {}],
5: [function (t, e, n) {
"use strict";
e.exports = function () {
function t() {
return Math.floor(65536 * (1 + Math.random())).toString(16).substring(1)
}
return function () {
return t() + t() + "-" + t() + "-" + t() + "-" + t() + "-" + t() + t() + t()
}
}()
}, {}],
6: [function (t, e, n) {
"use strict";
var r = t("./class"), o = t("./dom"), l = n.toInt = function (t) {
return parseInt(t, 10) || 0
}, i = n.clone = function (t) {
if (t) {
if (t.constructor === Array) return t.map(i);
if ("object" == typeof t) {
var e = {};
for (var n in t) e[n] = i(t[n]);
return e
}
return t
}
return null
};
n.extend = function (t, e) {
var n = i(t);
for (var r in e) n[r] = i(e[r]);
return n
}, n.isEditable = function (t) {
return o.matches(t, "input,[contenteditable]") || o.matches(t, "select,[contenteditable]") || o.matches(t, "textarea,[contenteditable]") || o.matches(t, "button,[contenteditable]")
}, n.removePsClasses = function (t) {
for (var e = r.list(t), n = 0; n < e.length; n++) {
var o = e[n];
0 === o.indexOf("ps-") && r.remove(t, o)
}
}, n.outerWidth = function (t) {
return l(o.css(t, "width")) + l(o.css(t, "paddingLeft")) + l(o.css(t, "paddingRight")) + l(o.css(t, "borderLeftWidth")) + l(o.css(t, "borderRightWidth"))
}, n.startScrolling = function (t, e) {
r.add(t, "ps-in-scrolling"), "undefined" != typeof e ? r.add(t, "ps-" + e) : (r.add(t, "ps-x"), r.add(t, "ps-y"))
}, n.stopScrolling = function (t, e) {
r.remove(t, "ps-in-scrolling"), "undefined" != typeof e ? r.remove(t, "ps-" + e) : (r.remove(t, "ps-x"), r.remove(t, "ps-y"))
}, n.env = {
isWebKit: "WebkitAppearance" in document.documentElement.style,
supportsTouch: "ontouchstart" in window || window.DocumentTouch && document instanceof window.DocumentTouch,
supportsIePointer: null !== window.navigator.msMaxTouchPoints
}
}, {"./class": 2, "./dom": 3}],
7: [function (t, e, n) {
"use strict";
var r = t("./plugin/destroy"), o = t("./plugin/initialize"), l = t("./plugin/update");
e.exports = {initialize: o, update: l, destroy: r}
}, {"./plugin/destroy": 9, "./plugin/initialize": 17, "./plugin/update": 21}],
8: [function (t, e, n) {
"use strict";
e.exports = {
handlers: ["click-rail", "drag-scrollbar", "keyboard", "wheel", "touch"],
maxScrollbarLength: null,
minScrollbarLength: null,
scrollXMarginOffset: 0,
scrollYMarginOffset: 0,
suppressScrollX: !1,
suppressScrollY: !1,
swipePropagation: !0,
useBothWheelAxes: !1,
wheelPropagation: !1,
wheelSpeed: 1,
theme: "default"
}
}, {}],
9: [function (t, e, n) {
"use strict";
var r = t("../lib/helper"), o = t("../lib/dom"), l = t("./instances");
e.exports = function (t) {
var e = l.get(t);
e && (e.event.unbindAll(), o.remove(e.scrollbarX), o.remove(e.scrollbarY), o.remove(e.scrollbarXRail), o.remove(e.scrollbarYRail), r.removePsClasses(t), l.remove(t))
}
}, {"../lib/dom": 3, "../lib/helper": 6, "./instances": 18}],
10: [function (t, e, n) {
"use strict";
function r(t, e) {
function n(t) {
return t.getBoundingClientRect()
}
var r = function (t) {
t.stopPropagation()
};
e.event.bind(e.scrollbarY, "click", r), e.event.bind(e.scrollbarYRail, "click", function (r) {
var o = r.pageY - window.pageYOffset - n(e.scrollbarYRail).top, s = o > e.scrollbarYTop ? 1 : -1;
i(t, "top", t.scrollTop + s * e.containerHeight), l(t), r.stopPropagation()
}), e.event.bind(e.scrollbarX, "click", r), e.event.bind(e.scrollbarXRail, "click", function (r) {
var o = r.pageX - window.pageXOffset - n(e.scrollbarXRail).left, s = o > e.scrollbarXLeft ? 1 : -1;
i(t, "left", t.scrollLeft + s * e.containerWidth), l(t), r.stopPropagation()
})
}
var o = t("../instances"), l = t("../update-geometry"), i = t("../update-scroll");
e.exports = function (t) {
var e = o.get(t);
r(t, e)
}
}, {"../instances": 18, "../update-geometry": 19, "../update-scroll": 20}],
11: [function (t, e, n) {
"use strict";
function r(t, e) {
function n(n) {
var o = r + n * e.railXRatio,
i = Math.max(0, e.scrollbarXRail.getBoundingClientRect().left) + e.railXRatio * (e.railXWidth - e.scrollbarXWidth);
o < 0 ? e.scrollbarXLeft = 0 : o > i ? e.scrollbarXLeft = i : e.scrollbarXLeft = o;
var s = l.toInt(e.scrollbarXLeft * (e.contentWidth - e.containerWidth) / (e.containerWidth - e.railXRatio * e.scrollbarXWidth)) - e.negativeScrollAdjustment;
c(t, "left", s)
}
var r = null, o = null, s = function (e) {
n(e.pageX - o), a(t), e.stopPropagation(), e.preventDefault()
}, u = function () {
l.stopScrolling(t, "x"), e.event.unbind(e.ownerDocument, "mousemove", s)
};
e.event.bind(e.scrollbarX, "mousedown", function (n) {
o = n.pageX, r = l.toInt(i.css(e.scrollbarX, "left")) * e.railXRatio, l.startScrolling(t, "x"), e.event.bind(e.ownerDocument, "mousemove", s), e.event.once(e.ownerDocument, "mouseup", u), n.stopPropagation(), n.preventDefault()
})
}
function o(t, e) {
function n(n) {
var o = r + n * e.railYRatio,
i = Math.max(0, e.scrollbarYRail.getBoundingClientRect().top) + e.railYRatio * (e.railYHeight - e.scrollbarYHeight);
o < 0 ? e.scrollbarYTop = 0 : o > i ? e.scrollbarYTop = i : e.scrollbarYTop = o;
var s = l.toInt(e.scrollbarYTop * (e.contentHeight - e.containerHeight) / (e.containerHeight - e.railYRatio * e.scrollbarYHeight));
c(t, "top", s)
}
var r = null, o = null, s = function (e) {
n(e.pageY - o), a(t), e.stopPropagation(), e.preventDefault()
}, u = function () {
l.stopScrolling(t, "y"), e.event.unbind(e.ownerDocument, "mousemove", s)
};
e.event.bind(e.scrollbarY, "mousedown", function (n) {
o = n.pageY, r = l.toInt(i.css(e.scrollbarY, "top")) * e.railYRatio, l.startScrolling(t, "y"), e.event.bind(e.ownerDocument, "mousemove", s), e.event.once(e.ownerDocument, "mouseup", u), n.stopPropagation(), n.preventDefault()
})
}
var l = t("../../lib/helper"), i = t("../../lib/dom"), s = t("../instances"), a = t("../update-geometry"),
c = t("../update-scroll");
e.exports = function (t) {
var e = s.get(t);
r(t, e), o(t, e)
}
}, {
"../../lib/dom": 3,
"../../lib/helper": 6,
"../instances": 18,
"../update-geometry": 19,
"../update-scroll": 20
}],
12: [function (t, e, n) {
"use strict";
function r(t, e) {
function n(n, r) {
var o = t.scrollTop;
if (0 === n) {
if (!e.scrollbarYActive) return !1;
if (0 === o && r > 0 || o >= e.contentHeight - e.containerHeight && r < 0) return !e.settings.wheelPropagation
}
var l = t.scrollLeft;
if (0 === r) {
if (!e.scrollbarXActive) return !1;
if (0 === l && n < 0 || l >= e.contentWidth - e.containerWidth && n > 0) return !e.settings.wheelPropagation
}
return !0
}
var r = !1;
e.event.bind(t, "mouseenter", function () {
r = !0
}), e.event.bind(t, "mouseleave", function () {
r = !1
});
var i = !1;
e.event.bind(e.ownerDocument, "keydown", function (c) {
if (!(c.isDefaultPrevented && c.isDefaultPrevented() || c.defaultPrevented)) {
var u = l.matches(e.scrollbarX, ":focus") || l.matches(e.scrollbarY, ":focus");
if (r || u) {
var d = document.activeElement ? document.activeElement : e.ownerDocument.activeElement;
if (d) {
if ("IFRAME" === d.tagName) d = d.contentDocument.activeElement; else for (; d.shadowRoot;) d = d.shadowRoot.activeElement;
if (o.isEditable(d)) return
}
var p = 0, f = 0;
switch (c.which) {
case 37:
p = c.metaKey ? -e.contentWidth : c.altKey ? -e.containerWidth : -30;
break;
case 38:
f = c.metaKey ? e.contentHeight : c.altKey ? e.containerHeight : 30;
break;
case 39:
p = c.metaKey ? e.contentWidth : c.altKey ? e.containerWidth : 30;
break;
case 40:
f = c.metaKey ? -e.contentHeight : c.altKey ? -e.containerHeight : -30;
break;
case 33:
f = 90;
break;
case 32:
f = c.shiftKey ? 90 : -90;
break;
case 34:
f = -90;
break;
case 35:
f = c.ctrlKey ? -e.contentHeight : -e.containerHeight;
break;
case 36:
f = c.ctrlKey ? t.scrollTop : e.containerHeight;
break;
default:
return
}
a(t, "top", t.scrollTop - f), a(t, "left", t.scrollLeft + p), s(t), i = n(p, f), i && c.preventDefault()
}
}
})
}
var o = t("../../lib/helper"), l = t("../../lib/dom"), i = t("../instances"), s = t("../update-geometry"),
a = t("../update-scroll");
e.exports = function (t) {
var e = i.get(t);
r(t, e)
}
}, {
"../../lib/dom": 3,
"../../lib/helper": 6,
"../instances": 18,
"../update-geometry": 19,
"../update-scroll": 20
}],
13: [function (t, e, n) {
"use strict";
function r(t, e) {
function n(n, r) {
var o = t.scrollTop;
if (0 === n) {
if (!e.scrollbarYActive) return !1;
if (0 === o && r > 0 || o >= e.contentHeight - e.containerHeight && r < 0) return !e.settings.wheelPropagation
}
var l = t.scrollLeft;
if (0 === r) {
if (!e.scrollbarXActive) return !1;
if (0 === l && n < 0 || l >= e.contentWidth - e.containerWidth && n > 0) return !e.settings.wheelPropagation
}
return !0
}
function r(t) {
var e = t.deltaX, n = -1 * t.deltaY;
return "undefined" != typeof e && "undefined" != typeof n || (e = -1 * t.wheelDeltaX / 6, n = t.wheelDeltaY / 6), t.deltaMode && 1 === t.deltaMode && (e *= 10, n *= 10), e !== e && n !== n && (e = 0, n = t.wheelDelta), t.shiftKey ? [-n, -e] : [e, n]
}
function o(e, n) {
var r = t.querySelector("textarea:hover, select[multiple]:hover, .ps-child:hover");
if (r) {
if (!window.getComputedStyle(r).overflow.match(/(scroll|auto)/)) return !1;
var o = r.scrollHeight - r.clientHeight;
if (o > 0 && !(0 === r.scrollTop && n > 0 || r.scrollTop === o && n < 0)) return !0;
var l = r.scrollLeft - r.clientWidth;
if (l > 0 && !(0 === r.scrollLeft && e < 0 || r.scrollLeft === l && e > 0)) return !0
}
return !1
}
function s(s) {
var c = r(s), u = c[0], d = c[1];
o(u, d) || (a = !1, e.settings.useBothWheelAxes ? e.scrollbarYActive && !e.scrollbarXActive ? (d ? i(t, "top", t.scrollTop - d * e.settings.wheelSpeed) : i(t, "top", t.scrollTop + u * e.settings.wheelSpeed), a = !0) : e.scrollbarXActive && !e.scrollbarYActive && (u ? i(t, "left", t.scrollLeft + u * e.settings.wheelSpeed) : i(t, "left", t.scrollLeft - d * e.settings.wheelSpeed), a = !0) : (i(t, "top", t.scrollTop - d * e.settings.wheelSpeed), i(t, "left", t.scrollLeft + u * e.settings.wheelSpeed)), l(t), a = a || n(u, d), a && (s.stopPropagation(), s.preventDefault()))
}
var a = !1;
"undefined" != typeof window.onwheel ? e.event.bind(t, "wheel", s) : "undefined" != typeof window.onmousewheel && e.event.bind(t, "mousewheel", s)
}
var o = t("../instances"), l = t("../update-geometry"), i = t("../update-scroll");
e.exports = function (t) {
var e = o.get(t);
r(t, e)
}
}, {"../instances": 18, "../update-geometry": 19, "../update-scroll": 20}],
14: [function (t, e, n) {
"use strict";
function r(t, e) {
e.event.bind(t, "scroll", function () {
l(t)
})
}
var o = t("../instances"), l = t("../update-geometry");
e.exports = function (t) {
var e = o.get(t);
r(t, e)
}
}, {"../instances": 18, "../update-geometry": 19}],
15: [function (t, e, n) {
"use strict";
function r(t, e) {
function n() {
var t = window.getSelection ? window.getSelection() : document.getSelection ? document.getSelection() : "";
return 0 === t.toString().length ? null : t.getRangeAt(0).commonAncestorContainer
}
function r() {
c || (c = setInterval(function () {
return l.get(t) ? (s(t, "top", t.scrollTop + u.top), s(t, "left", t.scrollLeft + u.left), void i(t)) : void clearInterval(c)
}, 50))
}
function a() {
c && (clearInterval(c), c = null), o.stopScrolling(t)
}
var c = null, u = {top: 0, left: 0}, d = !1;
e.event.bind(e.ownerDocument, "selectionchange", function () {
t.contains(n()) ? d = !0 : (d = !1, a())
}), e.event.bind(window, "mouseup", function () {
d && (d = !1, a())
}), e.event.bind(window, "keyup", function () {
d && (d = !1, a())
}), e.event.bind(window, "mousemove", function (e) {
if (d) {
var n = {x: e.pageX, y: e.pageY}, l = {
left: t.offsetLeft,
right: t.offsetLeft + t.offsetWidth,
top: t.offsetTop,
bottom: t.offsetTop + t.offsetHeight
};
n.x < l.left + 3 ? (u.left = -5, o.startScrolling(t, "x")) : n.x > l.right - 3 ? (u.left = 5, o.startScrolling(t, "x")) : u.left = 0, n.y < l.top + 3 ? (l.top + 3 - n.y < 5 ? u.top = -5 : u.top = -20, o.startScrolling(t, "y")) : n.y > l.bottom - 3 ? (n.y - l.bottom + 3 < 5 ? u.top = 5 : u.top = 20, o.startScrolling(t, "y")) : u.top = 0, 0 === u.top && 0 === u.left ? a() : r()
}
})
}
var o = t("../../lib/helper"), l = t("../instances"), i = t("../update-geometry"), s = t("../update-scroll");
e.exports = function (t) {
var e = l.get(t);
r(t, e)
}
}, {"../../lib/helper": 6, "../instances": 18, "../update-geometry": 19, "../update-scroll": 20}],
16: [function (t, e, n) {
"use strict";
function r(t, e, n, r) {
function o(n, r) {
var o = t.scrollTop, l = t.scrollLeft, i = Math.abs(n), s = Math.abs(r);
if (s > i) {
if (r < 0 && o === e.contentHeight - e.containerHeight || r > 0 && 0 === o) return !e.settings.swipePropagation
} else if (i > s && (n < 0 && l === e.contentWidth - e.containerWidth || n > 0 && 0 === l)) return !e.settings.swipePropagation;
return !0
}
function a(e, n) {
s(t, "top", t.scrollTop - n), s(t, "left", t.scrollLeft - e), i(t)
}
function c() {
w = !0
}
function u() {
w = !1
}
function d(t) {
return t.targetTouches ? t.targetTouches[0] : t
}
function p(t) {
return !(!t.targetTouches || 1 !== t.targetTouches.length) || !(!t.pointerType || "mouse" === t.pointerType || t.pointerType === t.MSPOINTER_TYPE_MOUSE)
}
function f(t) {
if (p(t)) {
Y = !0;
var e = d(t);
g.pageX = e.pageX, g.pageY = e.pageY, v = (new Date).getTime(), null !== y && clearInterval(y), t.stopPropagation()
}
}
function h(t) {
if (!Y && e.settings.swipePropagation && f(t), !w && Y && p(t)) {
var n = d(t), r = {pageX: n.pageX, pageY: n.pageY}, l = r.pageX - g.pageX, i = r.pageY - g.pageY;
a(l, i), g = r;
var s = (new Date).getTime(), c = s - v;
c > 0 && (m.x = l / c, m.y = i / c, v = s), o(l, i) && (t.stopPropagation(), t.preventDefault())
}
}
function b() {
!w && Y && (Y = !1, clearInterval(y), y = setInterval(function () {
return l.get(t) && (m.x || m.y) ? Math.abs(m.x) < .01 && Math.abs(m.y) < .01 ? void clearInterval(y) : (a(30 * m.x, 30 * m.y), m.x *= .8, void (m.y *= .8)) : void clearInterval(y)
}, 10))
}
var g = {}, v = 0, m = {}, y = null, w = !1, Y = !1;
n && (e.event.bind(window, "touchstart", c), e.event.bind(window, "touchend", u), e.event.bind(t, "touchstart", f), e.event.bind(t, "touchmove", h), e.event.bind(t, "touchend", b)), r && (window.PointerEvent ? (e.event.bind(window, "pointerdown", c), e.event.bind(window, "pointerup", u), e.event.bind(t, "pointerdown", f), e.event.bind(t, "pointermove", h), e.event.bind(t, "pointerup", b)) : window.MSPointerEvent && (e.event.bind(window, "MSPointerDown", c), e.event.bind(window, "MSPointerUp", u), e.event.bind(t, "MSPointerDown", f), e.event.bind(t, "MSPointerMove", h), e.event.bind(t, "MSPointerUp", b)))
}
var o = t("../../lib/helper"), l = t("../instances"), i = t("../update-geometry"), s = t("../update-scroll");
e.exports = function (t) {
if (o.env.supportsTouch || o.env.supportsIePointer) {
var e = l.get(t);
r(t, e, o.env.supportsTouch, o.env.supportsIePointer)
}
}
}, {"../../lib/helper": 6, "../instances": 18, "../update-geometry": 19, "../update-scroll": 20}],
17: [function (t, e, n) {
"use strict";
var r = t("../lib/helper"), o = t("../lib/class"), l = t("./instances"), i = t("./update-geometry"), s = {
"click-rail": t("./handler/click-rail"),
"drag-scrollbar": t("./handler/drag-scrollbar"),
keyboard: t("./handler/keyboard"),
wheel: t("./handler/mouse-wheel"),
touch: t("./handler/touch"),
selection: t("./handler/selection")
}, a = t("./handler/native-scroll");
e.exports = function (t, e) {
e = "object" == typeof e ? e : {}, o.add(t, "ps-container");
var n = l.add(t);
n.settings = r.extend(n.settings, e), o.add(t, "ps-theme-" + n.settings.theme), n.settings.handlers.forEach(function (e) {
s[e](t)
}), a(t), i(t)
}
}, {
"../lib/class": 2,
"../lib/helper": 6,
"./handler/click-rail": 10,
"./handler/drag-scrollbar": 11,
"./handler/keyboard": 12,
"./handler/mouse-wheel": 13,
"./handler/native-scroll": 14,
"./handler/selection": 15,
"./handler/touch": 16,
"./instances": 18,
"./update-geometry": 19
}],
18: [function (t, e, n) {
"use strict";
function r(t) {
function e() {
a.add(t, "ps-focus")
}
function n() {
a.remove(t, "ps-focus")
}
var r = this;
r.settings = s.clone(c), r.containerWidth = null, r.containerHeight = null, r.contentWidth = null, r.contentHeight = null, r.isRtl = "rtl" === u.css(t, "direction"), r.isNegativeScroll = function () {
var e = t.scrollLeft, n = null;
return t.scrollLeft = -1, n = t.scrollLeft < 0, t.scrollLeft = e, n
}(), r.negativeScrollAdjustment = r.isNegativeScroll ? t.scrollWidth - t.clientWidth : 0, r.event = new d, r.ownerDocument = t.ownerDocument || document, r.scrollbarXRail = u.appendTo(u.e("div", "ps-scrollbar-x-rail"), t), r.scrollbarX = u.appendTo(u.e("div", "ps-scrollbar-x"), r.scrollbarXRail), r.scrollbarX.setAttribute("tabindex", 0), r.event.bind(r.scrollbarX, "focus", e), r.event.bind(r.scrollbarX, "blur", n), r.scrollbarXActive = null, r.scrollbarXWidth = null, r.scrollbarXLeft = null, r.scrollbarXBottom = s.toInt(u.css(r.scrollbarXRail, "bottom")), r.isScrollbarXUsingBottom = r.scrollbarXBottom === r.scrollbarXBottom, r.scrollbarXTop = r.isScrollbarXUsingBottom ? null : s.toInt(u.css(r.scrollbarXRail, "top")), r.railBorderXWidth = s.toInt(u.css(r.scrollbarXRail, "borderLeftWidth")) + s.toInt(u.css(r.scrollbarXRail, "borderRightWidth")), u.css(r.scrollbarXRail, "display", "block"), r.railXMarginWidth = s.toInt(u.css(r.scrollbarXRail, "marginLeft")) + s.toInt(u.css(r.scrollbarXRail, "marginRight")), u.css(r.scrollbarXRail, "display", ""), r.railXWidth = null, r.railXRatio = null, r.scrollbarYRail = u.appendTo(u.e("div", "ps-scrollbar-y-rail"), t), r.scrollbarY = u.appendTo(u.e("div", "ps-scrollbar-y"), r.scrollbarYRail), r.scrollbarY.setAttribute("tabindex", 0), r.event.bind(r.scrollbarY, "focus", e), r.event.bind(r.scrollbarY, "blur", n), r.scrollbarYActive = null, r.scrollbarYHeight = null, r.scrollbarYTop = null, r.scrollbarYRight = s.toInt(u.css(r.scrollbarYRail, "right")), r.isScrollbarYUsingRight = r.scrollbarYRight === r.scrollbarYRight, r.scrollbarYLeft = r.isScrollbarYUsingRight ? null : s.toInt(u.css(r.scrollbarYRail, "left")), r.scrollbarYOuterWidth = r.isRtl ? s.outerWidth(r.scrollbarY) : null, r.railBorderYWidth = s.toInt(u.css(r.scrollbarYRail, "borderTopWidth")) + s.toInt(u.css(r.scrollbarYRail, "borderBottomWidth")), u.css(r.scrollbarYRail, "display", "block"), r.railYMarginHeight = s.toInt(u.css(r.scrollbarYRail, "marginTop")) + s.toInt(u.css(r.scrollbarYRail, "marginBottom")), u.css(r.scrollbarYRail, "display", ""), r.railYHeight = null, r.railYRatio = null
}
function o(t) {
return t.getAttribute("data-ps-id")
}
function l(t, e) {
t.setAttribute("data-ps-id", e)
}
function i(t) {
t.removeAttribute("data-ps-id")
}
var s = t("../lib/helper"), a = t("../lib/class"), c = t("./default-setting"), u = t("../lib/dom"),
d = t("../lib/event-manager"), p = t("../lib/guid"), f = {};
n.add = function (t) {
var e = p();
return l(t, e), f[e] = new r(t), f[e]
}, n.remove = function (t) {
delete f[o(t)], i(t)
}, n.get = function (t) {
return f[o(t)]
}
}, {
"../lib/class": 2,
"../lib/dom": 3,
"../lib/event-manager": 4,
"../lib/guid": 5,
"../lib/helper": 6,
"./default-setting": 8
}],
19: [function (t, e, n) {
"use strict";
function r(t, e) {
return t.settings.minScrollbarLength && (e = Math.max(e, t.settings.minScrollbarLength)), t.settings.maxScrollbarLength && (e = Math.min(e, t.settings.maxScrollbarLength)), e
}
function o(t, e) {
var n = {width: e.railXWidth};
e.isRtl ? n.left = e.negativeScrollAdjustment + t.scrollLeft + e.containerWidth - e.contentWidth : n.left = t.scrollLeft, e.isScrollbarXUsingBottom ? n.bottom = e.scrollbarXBottom - t.scrollTop : n.top = e.scrollbarXTop + t.scrollTop, s.css(e.scrollbarXRail, n);
var r = {top: t.scrollTop, height: e.railYHeight};
e.isScrollbarYUsingRight ? e.isRtl ? r.right = e.contentWidth - (e.negativeScrollAdjustment + t.scrollLeft) - e.scrollbarYRight - e.scrollbarYOuterWidth : r.right = e.scrollbarYRight - t.scrollLeft : e.isRtl ? r.left = e.negativeScrollAdjustment + t.scrollLeft + 2 * e.containerWidth - e.contentWidth - e.scrollbarYLeft - e.scrollbarYOuterWidth : r.left = e.scrollbarYLeft + t.scrollLeft, s.css(e.scrollbarYRail, r), s.css(e.scrollbarX, {
left: e.scrollbarXLeft,
width: e.scrollbarXWidth - e.railBorderXWidth
}), s.css(e.scrollbarY, {top: e.scrollbarYTop, height: e.scrollbarYHeight - e.railBorderYWidth})
}
var l = t("../lib/helper"), i = t("../lib/class"), s = t("../lib/dom"), a = t("./instances"),
c = t("./update-scroll");
e.exports = function (t) {
var e = a.get(t);
e.containerWidth = t.clientWidth, e.containerHeight = t.clientHeight, e.contentWidth = t.scrollWidth, e.contentHeight = t.scrollHeight;
var n;
t.contains(e.scrollbarXRail) || (n = s.queryChildren(t, ".ps-scrollbar-x-rail"), n.length > 0 && n.forEach(function (t) {
s.remove(t)
}), s.appendTo(e.scrollbarXRail, t)), t.contains(e.scrollbarYRail) || (n = s.queryChildren(t, ".ps-scrollbar-y-rail"), n.length > 0 && n.forEach(function (t) {
s.remove(t)
}), s.appendTo(e.scrollbarYRail, t)), !e.settings.suppressScrollX && e.containerWidth + e.settings.scrollXMarginOffset < e.contentWidth ? (e.scrollbarXActive = !0, e.railXWidth = e.containerWidth - e.railXMarginWidth, e.railXRatio = e.containerWidth / e.railXWidth, e.scrollbarXWidth = r(e, l.toInt(e.railXWidth * e.containerWidth / e.contentWidth)), e.scrollbarXLeft = l.toInt((e.negativeScrollAdjustment + t.scrollLeft) * (e.railXWidth - e.scrollbarXWidth) / (e.contentWidth - e.containerWidth))) : e.scrollbarXActive = !1, !e.settings.suppressScrollY && e.containerHeight + e.settings.scrollYMarginOffset < e.contentHeight ? (e.scrollbarYActive = !0, e.railYHeight = e.containerHeight - e.railYMarginHeight, e.railYRatio = e.containerHeight / e.railYHeight, e.scrollbarYHeight = r(e, l.toInt(e.railYHeight * e.containerHeight / e.contentHeight)), e.scrollbarYTop = l.toInt(t.scrollTop * (e.railYHeight - e.scrollbarYHeight) / (e.contentHeight - e.containerHeight))) : e.scrollbarYActive = !1, e.scrollbarXLeft >= e.railXWidth - e.scrollbarXWidth && (e.scrollbarXLeft = e.railXWidth - e.scrollbarXWidth), e.scrollbarYTop >= e.railYHeight - e.scrollbarYHeight && (e.scrollbarYTop = e.railYHeight - e.scrollbarYHeight), o(t, e), e.scrollbarXActive ? i.add(t, "ps-active-x") : (i.remove(t, "ps-active-x"), e.scrollbarXWidth = 0, e.scrollbarXLeft = 0, c(t, "left", 0)), e.scrollbarYActive ? i.add(t, "ps-active-y") : (i.remove(t, "ps-active-y"), e.scrollbarYHeight = 0, e.scrollbarYTop = 0, c(t, "top", 0))
}
}, {"../lib/class": 2, "../lib/dom": 3, "../lib/helper": 6, "./instances": 18, "./update-scroll": 20}],
20: [function (t, e, n) {
"use strict";
var r, o, l = t("./instances"), i = function (t) {
var e = document.createEvent("Event");
return e.initEvent(t, !0, !0), e
};
e.exports = function (t, e, n) {
if ("undefined" == typeof t) throw"You must provide an element to the update-scroll function";
if ("undefined" == typeof e) throw"You must provide an axis to the update-scroll function";
if ("undefined" == typeof n) throw"You must provide a value to the update-scroll function";
"top" === e && n <= 0 && (t.scrollTop = n = 0, t.dispatchEvent(i("ps-y-reach-start"))), "left" === e && n <= 0 && (t.scrollLeft = n = 0, t.dispatchEvent(i("ps-x-reach-start")));
var s = l.get(t);
"top" === e && n >= s.contentHeight - s.containerHeight && (n = s.contentHeight - s.containerHeight, n - t.scrollTop <= 1 ? n = t.scrollTop : t.scrollTop = n, t.dispatchEvent(i("ps-y-reach-end"))), "left" === e && n >= s.contentWidth - s.containerWidth && (n = s.contentWidth - s.containerWidth, n - t.scrollLeft <= 1 ? n = t.scrollLeft : t.scrollLeft = n, t.dispatchEvent(i("ps-x-reach-end"))), r || (r = t.scrollTop), o || (o = t.scrollLeft), "top" === e && n < r && t.dispatchEvent(i("ps-scroll-up")), "top" === e && n > r && t.dispatchEvent(i("ps-scroll-down")), "left" === e && n < o && t.dispatchEvent(i("ps-scroll-left")), "left" === e && n > o && t.dispatchEvent(i("ps-scroll-right")), "top" === e && (t.scrollTop = r = n, t.dispatchEvent(i("ps-scroll-y"))), "left" === e && (t.scrollLeft = o = n, t.dispatchEvent(i("ps-scroll-x")))
}
}, {"./instances": 18}],
21: [function (t, e, n) {
"use strict";
var r = t("../lib/helper"), o = t("../lib/dom"), l = t("./instances"), i = t("./update-geometry"),
s = t("./update-scroll");
e.exports = function (t) {
var e = l.get(t);
e && (e.negativeScrollAdjustment = e.isNegativeScroll ? t.scrollWidth - t.clientWidth : 0, o.css(e.scrollbarXRail, "display", "block"), o.css(e.scrollbarYRail, "display", "block"), e.railXMarginWidth = r.toInt(o.css(e.scrollbarXRail, "marginLeft")) + r.toInt(o.css(e.scrollbarXRail, "marginRight")), e.railYMarginHeight = r.toInt(o.css(e.scrollbarYRail, "marginTop")) + r.toInt(o.css(e.scrollbarYRail, "marginBottom")), o.css(e.scrollbarXRail, "display", "none"), o.css(e.scrollbarYRail, "display", "none"), i(t), s(t, "top", t.scrollTop), s(t, "left", t.scrollLeft), o.css(e.scrollbarXRail, "display", ""), o.css(e.scrollbarYRail, "display", ""))
}
}, {"../lib/dom": 3, "../lib/helper": 6, "./instances": 18, "./update-geometry": 19, "./update-scroll": 20}]
}, {}, [1]);
/* */
'use strict';
(function ($) {
var $storage = true;
var added_ids = [];
var key = "";
try {
$storage = ('sessionStorage' in window && window.sessionStorage !== null);
window.sessionStorage.setItem('woosw', 'test');
window.sessionStorage.removeItem('woosw');
} catch (err) {
$storage = false;
}
$(function () {
if (key === null || key === undefined || key === '') {
key = woosw_get_key();
}
// Load data for the first time
woosw_load_data();
if ($('.woosw-custom-menu-item').length) {
// load the count when having a custom menu item
woosw_load_count();
}
if (woosw_vars.button_action === 'message') {
$.notiny.addTheme('woosw', {
notification_class: 'notiny-theme-woosw',
});
}
});
$(document).on('woosw_refresh_data', function () {
woosw_get_data();
});
$(document).on('woosw_refresh_count', function () {
woosw_load_count();
});
// woovr
$(document).on('woovr_selected', function (e, selected, variations) {
var id = selected.attr('data-id');
var pid = selected.attr('data-pid');
if (id > 0) {
$('.woosw-btn-' + pid).attr('data-id', id).removeClass('woosw-btn-added woosw-added');
// refresh button
woosw_refresh_button_id(id);
} else {
$('.woosw-btn-' + pid).attr('data-id', pid).removeClass('woosw-btn-added woosw-added');
// refresh button
woosw_refresh_button_id(pid);
}
});
// found variation
$(document).on('found_variation', function (e, t) {
var product_id = $(e['target']).attr('data-product_id');
// change id
$('.woosw-btn-' + product_id).attr('data-id', t.variation_id).removeClass('woosw-btn-added woosw-added');
// refresh button
woosw_refresh_button_id(t.variation_id);
});
// reset data
$(document).on('reset_data', function (e) {
var product_id = $(e['target']).attr('data-product_id');
// change id
$('.woosw-btn-' + product_id).attr('data-id', product_id).removeClass('woosw-btn-added woosw-added');
// refresh button
woosw_refresh_button_id(product_id);
});
// quick view
$(document).on('click touch',
'#woosw_wishlist .woosq-link, #woosw_wishlist .woosq-btn',
function (e) {
woosw_wishlist_hide();
e.preventDefault();
});
// add to wishlist
$(document).on('click touch', '.woosw-btn', function (e) {
var $this = $(this);
var id = $this.attr('data-id');
var pid = $this.attr('data-pid');
var product_id = $this.attr('data-product_id');
var product_name = $this.attr('data-product_name');
var product_image = $this.attr('data-product_image');
if (typeof pid !== typeof undefined && pid !== false) {
id = pid;
}
if (typeof product_id !== typeof undefined && product_id !== false) {
id = product_id;
}
// add product
var data = {
action: 'wishlist_add', product_id: id, nonce: woosw_vars.nonce,
};
if ($this.hasClass('woosw-added')) {
if (woosw_vars.button_action_added === 'page') {
// open wishlist page
window.location.href = woosw_vars.wishlist_url;
} else {
// open wishlist popup
if ($('#woosw_wishlist').hasClass('woosw-loaded')) {
woosw_wishlist_show();
} else {
woosw_wishlist_load();
}
}
} else {
$this.addClass('woosw-adding').find('.woosw-btn-icon').removeClass(woosw_vars.button_normal_icon + ' ' +
woosw_vars.button_added_icon).addClass(woosw_vars.button_loading_icon);
$.post(woosw_vars.ajax_url, data, function (response) {
$this.removeClass('woosw-adding').find('.woosw-btn-icon').removeClass(woosw_vars.button_loading_icon);
if (woosw_vars.button_action === 'list') {
if (response.content != null) {
$('#woosw_wishlist').html(response.content).addClass('woosw-loaded');
}
if (response.notice != null) {
woosw_notice(response.notice.replace('{name}',
'' + product_name + ''));
}
woosw_perfect_scrollbar();
woosw_wishlist_show();
}
if (woosw_vars.button_action === 'message') {
$('#woosw_wishlist').removeClass('woosw-loaded');
$.notiny({
theme: 'woosw',
position: woosw_vars.message_position,
image: product_image,
text: response.notice.replace('{name}',
'' + product_name + ''),
});
}
if (woosw_vars.button_action === 'no') {
// add to wishlist solely
$('#woosw_wishlist').removeClass('woosw-loaded');
}
if (response.count != null) {
woosw_change_count(response.count);
}
if (response.status === 1) {
woosw_refresh_button_id(id);
}
if ($storage && response.data) {
sessionStorage.setItem('woosw_data_' + response.data.key,
JSON.stringify(response.data));
}
if (response.data.fragments) {
woosw_refresh_fragments(response.data.fragments);
}
if (response.data.ids) {
woosw_refresh_buttons(response.data.ids);
woosw_refresh_ids(response.data.ids);
}
$(document.body).trigger('woosw_add', [id]);
});
}
e.preventDefault();
});
// remove product
$(document).on('click touch', '.woosw-item--remove span', function (e) {
var $this = $(this);
var key = $this.closest('.woosw-popup-inner').data('key');
var $this_item = $this.closest('.woosw-item');
var product_id = $this_item.attr('data-id');
var data = {
action: 'wishlist_remove',
product_id: product_id,
key: key,
nonce: woosw_vars.nonce,
};
$this.addClass('woosw-removing');
$.post(woosw_vars.ajax_url, data, function (response) {
$this.removeClass('woosw-removing');
$this_item.remove();
if (response.content != null) {
$('#woosw_wishlist').html(response.content).addClass('woosw-loaded');
}
if (response.notice != null) {
woosw_notice(response.notice);
}
if (response.count != null) {
woosw_change_count(response.count);
}
if ($storage && response.data) {
sessionStorage.setItem('woosw_data_' + response.data.key,
JSON.stringify(response.data));
}
if (response.data.fragments) {
woosw_refresh_fragments(response.data.fragments);
}
if (response.data.ids) {
woosw_refresh_buttons(response.data.ids);
woosw_refresh_ids(response.data.ids);
}
$(document.body).trigger('woosw_remove', [product_id]);
});
e.preventDefault();
});
// empty wishlist
$(document).on('click touch', '.woosw-empty', function (e) {
var $this = $(this);
if (confirm(woosw_vars.empty_confirm)) {
woosw_popup_loading();
var key = $this.closest('.woosw-popup-inner').data('key');
var data = {
action: 'wishlist_empty', key: key, nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
if (response.content != null) {
$('#woosw_wishlist').html(response.content).addClass('woosw-loaded');
}
if (response.notice != null) {
woosw_notice(response.notice);
}
if (response.count != null) {
woosw_change_count(response.count);
}
if ($storage && response.data) {
sessionStorage.setItem('woosw_data_' + response.data.key,
JSON.stringify(response.data));
}
if (response.data.fragments) {
woosw_refresh_fragments(response.data.fragments);
}
if (response.data.ids) {
woosw_refresh_buttons(response.data.ids);
woosw_refresh_ids(response.data.ids);
}
woosw_popup_loaded();
$(document.body).trigger('woosw_empty', [key]);
});
}
e.preventDefault();
});
// click on area
$(document).on('click touch', '.woosw-popup', function (e) {
var woosw_content = $('.woosw-popup-content');
if ($(e.target).closest(woosw_content).length == 0) {
woosw_wishlist_hide();
woosw_manage_hide();
}
});
// continue
$(document).on('click touch', '.woosw-continue', function (e) {
var url = $(this).attr('data-url');
woosw_wishlist_hide();
if (url !== '') {
window.location.href = url;
}
e.preventDefault();
});
// close
$(document).on('click touch', '#woosw_wishlist .woosw-popup-close', function (e) {
woosw_wishlist_hide();
e.preventDefault();
});
// manage close
$(document).on('click touch', '#woosw_manage .woosw-popup-close', function (e) {
woosw_manage_hide();
e.preventDefault();
});
// manage wishlists
$(document).on('click touch', '.woosw-manage', function (e) {
e.preventDefault();
woosw_popup_loading();
var data = {
action: 'manage_wishlists', nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
woosw_wishlist_hide();
$('#woosw_manage').html(response);
woosw_manage_show();
woosw_popup_loaded();
});
});
// add wishlist
$(document).on('click touch', '#woosw_add_wishlist', function (e) {
e.preventDefault();
woosw_popup_loading();
var name = $('#woosw_wishlist_name').val();
var data = {
action: 'add_wishlist', name: name, nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
$('#woosw_manage').html(response);
$('#woosw_wishlist').removeClass('woosw-loaded');
woosw_popup_loaded();
});
});
// set default
$(document).on('click touch', '.woosw-set-default', function (e) {
e.preventDefault();
woosw_popup_loading();
var key = $(this).data('key');
var data = {
action: 'set_default', key: key, nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
if (response.count != null) {
woosw_change_count(response.count);
}
if ((response.products != null) && response.products.length) {
response.products.forEach((product_id) => {
woosw_refresh_button_id(product_id);
});
}
$('#woosw_manage').html(response.content);
if ($storage && response.data) {
sessionStorage.setItem('woosw_data_' + response.data.key,
JSON.stringify(response.data));
}
if (response.data.fragments) {
woosw_refresh_fragments(response.data.fragments);
}
if (response.data.ids) {
woosw_refresh_buttons(response.data.ids);
woosw_refresh_ids(response.data.ids);
}
$('#woosw_wishlist').removeClass('woosw-loaded');
woosw_popup_loaded();
});
});
// delete wishlist
$(document).on('click touch', '.woosw-delete-wishlist', function (e) {
e.preventDefault();
if (confirm(woosw_vars.delete_confirm)) {
woosw_popup_loading();
var key = $(this).data('key');
var data = {
action: 'delete_wishlist', key: key, nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
$('#woosw_manage').html(response);
$('#woosw_wishlist').removeClass('woosw-loaded');
woosw_popup_loaded();
});
}
});
// view wishlist
$(document).on('click touch', '.woosw-view-wishlist', function (e) {
e.preventDefault();
woosw_popup_loading();
var key = $(this).data('key');
var data = {
action: 'view_wishlist', key: key, nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
woosw_manage_hide();
$('#woosw_wishlist').removeClass('woosw-loaded').html(response);
woosw_wishlist_show();
woosw_popup_loaded();
});
});
// menu item
$(document).on('click touch', '.woosw-menu-item a, .woosw-menu a', function (e) {
if (woosw_vars.menu_action === 'open_popup') {
e.preventDefault();
if ($('#woosw_wishlist').hasClass('woosw-loaded')) {
woosw_wishlist_show();
} else {
woosw_wishlist_load();
}
}
});
// copy link
$(document).on('click touch', '#woosw_copy_url, #woosw_copy_btn', function (e) {
e.preventDefault();
woosw_copy_to_clipboard('#woosw_copy_url');
});
// add note
$(document).on('click touch', '.woosw-item--note', function () {
if ($(this).closest('.woosw-item').find('.woosw-item--note-add').length) {
$(this).closest('.woosw-item').find('.woosw-item--note-add').show();
$(this).hide();
}
});
$(document).on('click touch', '.woosw_add_note', function (e) {
e.preventDefault();
woosw_popup_loading();
var $this = $(this);
var key = $this.closest('.woosw-popup-inner').data('key');
var product_id = $this.closest('.woosw-item').attr('data-id');
var note = $this.closest('.woosw-item').find('input[type="text"]').val();
var data = {
action: 'add_note',
key: key,
product_id: product_id,
note: woosw_html_entities(note),
nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
$this.closest('.woosw-item').find('.woosw-item--note').html(response).show();
$this.closest('.woosw-item').find('.woosw-item--note-add').hide();
woosw_popup_loaded();
});
});
// resize
$(window).on('resize', function () {
woosw_fix_height();
});
function woosw_wishlist_load() {
var data = {
action: 'wishlist_load',
nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
if (response.content != null) {
$('#woosw_wishlist').html(response.content);
}
if (response.count != null) {
if ($('#woosw_wishlist .woosw-items .woosw-item').length &&
($('#woosw_wishlist .woosw-items .woosw-item').length !=
response.count)) {
woosw_change_count(
$('#woosw_wishlist .woosw-items .woosw-item').length);
} else {
woosw_change_count(response.count);
}
}
if (response.notice != null) {
woosw_notice(response.notice);
}
$('#woosw_wishlist').addClass('woosw-loaded');
woosw_perfect_scrollbar();
woosw_wishlist_show();
});
}
function woosw_load_count() {
var data = {
action: 'wishlist_load_count',
nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
if (response.count != null) {
var count = response.count;
woosw_change_count(count);
$(document.body).trigger('woosw_load_count', [count]);
}
});
}
function woosw_wishlist_show() {
$('#woosw_wishlist').addClass('woosw-show');
woosw_fix_height();
$(document.body).trigger('woosw_wishlist_show');
}
function woosw_wishlist_hide() {
$('#woosw_wishlist').removeClass('woosw-show');
$(document.body).trigger('woosw_wishlist_hide');
}
function woosw_manage_show() {
$('#woosw_manage').addClass('woosw-show');
$(document.body).trigger('woosw_manage_show');
}
function woosw_manage_hide() {
$('#woosw_manage').removeClass('woosw-show');
$(document.body).trigger('woosw_manage_hide');
}
function woosw_popup_loading() {
$('.woosw-popup').addClass('woosw-loading');
}
function woosw_popup_loaded() {
$('.woosw-popup').removeClass('woosw-loading');
}
function woosw_change_count(count) {
$('#woosw_wishlist .woosw-count').html(count);
if (parseInt(count) > 0) {
$('.woosw-empty').show();
} else {
$('.woosw-empty').hide();
}
if ($('.woosw-menu-item .woosw-menu-item-inner').length) {
$('.woosw-menu-item .woosw-menu-item-inner').attr('data-count', count);
} else {
$('.woosw-menu-item a').html('' + woosw_vars.menu_text +
'');
}
$(document.body).trigger('woosw_change_count', [count]);
}
function woosw_notice(notice) {
$('.woosw-notice').html(notice);
woosw_notice_show();
setTimeout(function () {
woosw_notice_hide();
}, 3000);
}
function woosw_notice_show() {
$('#woosw_wishlist .woosw-notice').addClass('woosw-notice-show');
}
function woosw_notice_hide() {
$('#woosw_wishlist .woosw-notice').removeClass('woosw-notice-show');
}
function woosw_perfect_scrollbar() {
if (woosw_vars.perfect_scrollbar === 'yes') {
jQuery('#woosw_wishlist .woosw-popup-content-mid').perfectScrollbar({theme: 'wpc'});
}
}
function woosw_copy_url() {
var wooswURL = document.getElementById('woosw_copy_url');
wooswURL.select();
document.execCommand('copy');
alert(woosw_vars.copied_text + ' ' + wooswURL.value);
}
function woosw_copy_to_clipboard(el) {
// resolve the element
el = (typeof el === 'string') ? document.querySelector(el) : el;
// handle iOS as a special case
if (navigator.userAgent.match(/ipad|ipod|iphone/i)) {
// save current contentEditable/readOnly status
var editable = el.contentEditable;
var readOnly = el.readOnly;
// convert to editable with readonly to stop iOS keyboard opening
el.contentEditable = true;
el.readOnly = true;
// create a selectable range
var range = document.createRange();
range.selectNodeContents(el);
// select the range
var selection = window.getSelection();
selection.removeAllRanges();
selection.addRange(range);
el.setSelectionRange(0, 999999);
// restore contentEditable/readOnly to original state
el.contentEditable = editable;
el.readOnly = readOnly;
} else {
el.select();
}
// execute copy command
document.execCommand('copy');
// alert
alert(woosw_vars.copied_text + ' ' + el.value);
}
function woosw_html_entities(str) {
return String(str).replace(/&/g, '&').replace(//g, '>').replace(/"/g, '"');
}
function woosw_get_key() {
var result = [];
var characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
var charactersLength = characters.length;
for (var i = 0; i < 6; i++) {
result.push(
characters.charAt(Math.floor(Math.random() * charactersLength)));
}
return result.join('');
}
function woosw_fix_height() {
// fix for center only
jQuery('.woosw-popup-center .woosw-popup-content').height(2 * Math.floor(
jQuery('.woosw-popup-center .woosw-popup-content').height() / 2) +
2);
}
function woosw_load_data() {
if ($storage) {
try {
var data = JSON.parse(sessionStorage.getItem('woosw_data_' + key));
if (data.fragments) {
woosw_refresh_fragments(data.fragments);
}
if (data.ids) {
woosw_refresh_buttons(data.ids);
woosw_refresh_ids(data.ids);
}
if (data.key && (key === null || key === undefined || key === '')) {
}
} catch (err) {
woosw_get_data();
}
} else {
woosw_get_data();
}
}
function woosw_get_data() {
var data = {
action: 'woosw_get_data',
nonce: woosw_vars.nonce,
};
$.post(woosw_vars.ajax_url, data, function (response) {
if (response) {
if ($storage) {
sessionStorage.setItem('woosw_data_' + response.key,
JSON.stringify(response));
}
if (response.fragments) {
woosw_refresh_fragments(response.fragments);
}
if (response.ids) {
woosw_refresh_buttons(response.ids);
woosw_refresh_ids(response.ids);
}
if (response.key &&
(key === null || key === undefined || key === '' || key !==
response.key)) {
}
$(document.body).trigger('woosw_data_refreshed', [response]);
}
});
}
function woosw_refresh_fragments(fragments) {
$.each(fragments, function (key, value) {
$(key).replaceWith(value);
});
$(document.body).trigger('woosw_fragments_refreshed', [fragments]);
}
function woosw_refresh_ids(ids) {
added_ids = ids;
}
function woosw_refresh_buttons(ids) {
$('.woosw-btn').removeClass('woosw-btn-added woosw-added');
$('.woosw-btn:not(.woosw-btn-has-icon)').html(woosw_vars.button_text);
$('.woosw-btn.woosw-btn-has-icon').find('.woosw-btn-icon').removeClass(woosw_vars.button_added_icon).addClass(woosw_vars.button_normal_icon);
$('.woosw-btn.woosw-btn-has-icon').find('.woosw-btn-text').html(woosw_vars.button_text);
$.each(ids, function (key, value) {
$('.woosw-btn-' + key).addClass('woosw-btn-added woosw-added');
$('.woosw-btn-' + key + ':not(.woosw-btn-has-icon)').html(woosw_vars.button_text_added);
$('.woosw-btn-has-icon.woosw-btn-' + key).find('.woosw-btn-icon').removeClass(woosw_vars.button_normal_icon).addClass(woosw_vars.button_added_icon);
$('.woosw-btn-has-icon.woosw-btn-' + key).find('.woosw-btn-text').html(woosw_vars.button_text_added);
if (value.parent !== undefined) {
$('.woosw-btn-' + value.parent).addClass('woosw-btn-added woosw-added');
$('.woosw-btn-' + value.parent + ':not(.woosw-btn-has-icon)').html(woosw_vars.button_text_added);
$('.woosw-btn-has-icon.woosw-btn-' + value.parent).find('.woosw-btn-icon').removeClass(woosw_vars.button_normal_icon).addClass(woosw_vars.button_added_icon);
$('.woosw-btn-has-icon.woosw-btn-' + value.parent).find('.woosw-btn-text').html(woosw_vars.button_text_added);
}
});
$(document.body).trigger('woosw_buttons_refreshed', [ids]);
}
function woosw_refresh_button_id(id) {
$('.woosw-btn[data-id="' + id + '"]').removeClass('woosw-btn-added woosw-added');
$('.woosw-btn[data-id="' + id + '"]:not(.woosw-btn-has-icon)').html(woosw_vars.button_text);
$('.woosw-btn-has-icon.woosw-btn[data-id="' + id + '"]').find('.woosw-btn-icon').removeClass(woosw_vars.button_added_icon).addClass(woosw_vars.button_normal_icon);
$('.woosw-btn-has-icon.woosw-btn[data-id="' + id + '"]').find('.woosw-btn-text').html(woosw_vars.button_text);
$.each(added_ids, function (key) {
if (parseInt(key) === parseInt(id)) {
$('.woosw-btn[data-id="' + id + '"]').addClass('woosw-btn-added woosw-added');
$('.woosw-btn[data-id="' + id + '"]:not(.woosw-btn-has-icon)').html(woosw_vars.button_text_added);
$('.woosw-btn-has-icon.woosw-btn[data-id="' + id + '"]').find('.woosw-btn-icon').removeClass(woosw_vars.button_normal_icon).addClass(woosw_vars.button_added_icon);
$('.woosw-btn-has-icon.woosw-btn[data-id="' + id + '"]').find('.woosw-btn-text').html(woosw_vars.button_text_added);
}
});
$(document.body).trigger('woosw_refresh_button_id', [id, added_ids]);
}
})(jQuery);
/*
Copyright (C) Federico Zivolo 2020
Distributed under the MIT License (license terms are at http://opensource.org/licenses/MIT).
*/
(function (e, t) {
'object' == typeof exports && 'undefined' != typeof module ? module.exports = t() : 'function' == typeof define && define.amd ? define(t) : e.Popper = t()
})(this, function () {
'use strict';
function e(e) {
return e && '[object Function]' === {}.toString.call(e)
}
function t(e, t) {
if (1 !== e.nodeType) return [];
var o = e.ownerDocument.defaultView, n = o.getComputedStyle(e, null);
return t ? n[t] : n
}
function o(e) {
return 'HTML' === e.nodeName ? e : e.parentNode || e.host
}
function n(e) {
if (!e) return document.body;
switch (e.nodeName) {
case'HTML':
case'BODY':
return e.ownerDocument.body;
case'#document':
return e.body;
}
var i = t(e), r = i.overflow, p = i.overflowX, s = i.overflowY;
return /(auto|scroll|overlay)/.test(r + s + p) ? e : n(o(e))
}
function i(e) {
return e && e.referenceNode ? e.referenceNode : e
}
function r(e) {
return 11 === e ? re : 10 === e ? pe : re || pe
}
function p(e) {
if (!e) return document.documentElement;
for (var o = r(10) ? document.body : null, n = e.offsetParent || null; n === o && e.nextElementSibling;) n = (e = e.nextElementSibling).offsetParent;
var i = n && n.nodeName;
return i && 'BODY' !== i && 'HTML' !== i ? -1 !== ['TH', 'TD', 'TABLE'].indexOf(n.nodeName) && 'static' === t(n, 'position') ? p(n) : n : e ? e.ownerDocument.documentElement : document.documentElement
}
function s(e) {
var t = e.nodeName;
return 'BODY' !== t && ('HTML' === t || p(e.firstElementChild) === e)
}
function d(e) {
return null === e.parentNode ? e : d(e.parentNode)
}
function a(e, t) {
if (!e || !e.nodeType || !t || !t.nodeType) return document.documentElement;
var o = e.compareDocumentPosition(t) & Node.DOCUMENT_POSITION_FOLLOWING, n = o ? e : t, i = o ? t : e,
r = document.createRange();
r.setStart(n, 0), r.setEnd(i, 0);
var l = r.commonAncestorContainer;
if (e !== l && t !== l || n.contains(i)) return s(l) ? l : p(l);
var f = d(e);
return f.host ? a(f.host, t) : a(e, d(t).host)
}
function l(e) {
var t = 1 < arguments.length && void 0 !== arguments[1] ? arguments[1] : 'top',
o = 'top' === t ? 'scrollTop' : 'scrollLeft', n = e.nodeName;
if ('BODY' === n || 'HTML' === n) {
var i = e.ownerDocument.documentElement, r = e.ownerDocument.scrollingElement || i;
return r[o]
}
return e[o]
}
function f(e, t) {
var o = 2 < arguments.length && void 0 !== arguments[2] && arguments[2], n = l(t, 'top'), i = l(t, 'left'),
r = o ? -1 : 1;
return e.top += n * r, e.bottom += n * r, e.left += i * r, e.right += i * r, e
}
function m(e, t) {
var o = 'x' === t ? 'Left' : 'Top', n = 'Left' == o ? 'Right' : 'Bottom';
return parseFloat(e['border' + o + 'Width']) + parseFloat(e['border' + n + 'Width'])
}
function h(e, t, o, n) {
return ee(t['offset' + e], t['scroll' + e], o['client' + e], o['offset' + e], o['scroll' + e], r(10) ? parseInt(o['offset' + e]) + parseInt(n['margin' + ('Height' === e ? 'Top' : 'Left')]) + parseInt(n['margin' + ('Height' === e ? 'Bottom' : 'Right')]) : 0)
}
function c(e) {
var t = e.body, o = e.documentElement, n = r(10) && getComputedStyle(o);
return {height: h('Height', t, o, n), width: h('Width', t, o, n)}
}
function g(e) {
return le({}, e, {right: e.left + e.width, bottom: e.top + e.height})
}
function u(e) {
var o = {};
try {
if (r(10)) {
o = e.getBoundingClientRect();
var n = l(e, 'top'), i = l(e, 'left');
o.top += n, o.left += i, o.bottom += n, o.right += i
} else o = e.getBoundingClientRect()
} catch (t) {
}
var p = {left: o.left, top: o.top, width: o.right - o.left, height: o.bottom - o.top},
s = 'HTML' === e.nodeName ? c(e.ownerDocument) : {}, d = s.width || e.clientWidth || p.width,
a = s.height || e.clientHeight || p.height, f = e.offsetWidth - d, h = e.offsetHeight - a;
if (f || h) {
var u = t(e);
f -= m(u, 'x'), h -= m(u, 'y'), p.width -= f, p.height -= h
}
return g(p)
}
function b(e, o) {
var i = 2 < arguments.length && void 0 !== arguments[2] && arguments[2], p = r(10), s = 'HTML' === o.nodeName,
d = u(e), a = u(o), l = n(e), m = t(o), h = parseFloat(m.borderTopWidth), c = parseFloat(m.borderLeftWidth);
i && s && (a.top = ee(a.top, 0), a.left = ee(a.left, 0));
var b = g({top: d.top - a.top - h, left: d.left - a.left - c, width: d.width, height: d.height});
if (b.marginTop = 0, b.marginLeft = 0, !p && s) {
var w = parseFloat(m.marginTop), y = parseFloat(m.marginLeft);
b.top -= h - w, b.bottom -= h - w, b.left -= c - y, b.right -= c - y, b.marginTop = w, b.marginLeft = y
}
return (p && !i ? o.contains(l) : o === l && 'BODY' !== l.nodeName) && (b = f(b, o)), b
}
function w(e) {
var t = 1 < arguments.length && void 0 !== arguments[1] && arguments[1], o = e.ownerDocument.documentElement,
n = b(e, o), i = ee(o.clientWidth, window.innerWidth || 0), r = ee(o.clientHeight, window.innerHeight || 0),
p = t ? 0 : l(o), s = t ? 0 : l(o, 'left'),
d = {top: p - n.top + n.marginTop, left: s - n.left + n.marginLeft, width: i, height: r};
return g(d)
}
function y(e) {
var n = e.nodeName;
if ('BODY' === n || 'HTML' === n) return !1;
if ('fixed' === t(e, 'position')) return !0;
var i = o(e);
return !!i && y(i)
}
function E(e) {
if (!e || !e.parentElement || r()) return document.documentElement;
for (var o = e.parentElement; o && 'none' === t(o, 'transform');) o = o.parentElement;
return o || document.documentElement
}
function v(e, t, r, p) {
var s = 4 < arguments.length && void 0 !== arguments[4] && arguments[4], d = {top: 0, left: 0},
l = s ? E(e) : a(e, i(t));
if ('viewport' === p) d = w(l, s); else {
var f;
'scrollParent' === p ? (f = n(o(t)), 'BODY' === f.nodeName && (f = e.ownerDocument.documentElement)) : 'window' === p ? f = e.ownerDocument.documentElement : f = p;
var m = b(f, l, s);
if ('HTML' === f.nodeName && !y(l)) {
var h = c(e.ownerDocument), g = h.height, u = h.width;
d.top += m.top - m.marginTop, d.bottom = g + m.top, d.left += m.left - m.marginLeft, d.right = u + m.left
} else d = m
}
r = r || 0;
var v = 'number' == typeof r;
return d.left += v ? r : r.left || 0, d.top += v ? r : r.top || 0, d.right -= v ? r : r.right || 0, d.bottom -= v ? r : r.bottom || 0, d
}
function x(e) {
var t = e.width, o = e.height;
return t * o
}
function O(e, t, o, n, i) {
var r = 5 < arguments.length && void 0 !== arguments[5] ? arguments[5] : 0;
if (-1 === e.indexOf('auto')) return e;
var p = v(o, n, r, i), s = {
top: {width: p.width, height: t.top - p.top},
right: {width: p.right - t.right, height: p.height},
bottom: {width: p.width, height: p.bottom - t.bottom},
left: {width: t.left - p.left, height: p.height}
}, d = Object.keys(s).map(function (e) {
return le({key: e}, s[e], {area: x(s[e])})
}).sort(function (e, t) {
return t.area - e.area
}), a = d.filter(function (e) {
var t = e.width, n = e.height;
return t >= o.clientWidth && n >= o.clientHeight
}), l = 0 < a.length ? a[0].key : d[0].key, f = e.split('-')[1];
return l + (f ? '-' + f : '')
}
function L(e, t, o) {
var n = 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null, r = n ? E(t) : a(t, i(o));
return b(o, r, n)
}
function S(e) {
var t = e.ownerDocument.defaultView, o = t.getComputedStyle(e),
n = parseFloat(o.marginTop || 0) + parseFloat(o.marginBottom || 0),
i = parseFloat(o.marginLeft || 0) + parseFloat(o.marginRight || 0),
r = {width: e.offsetWidth + i, height: e.offsetHeight + n};
return r
}
function T(e) {
var t = {left: 'right', right: 'left', bottom: 'top', top: 'bottom'};
return e.replace(/left|right|bottom|top/g, function (e) {
return t[e]
})
}
function C(e, t, o) {
o = o.split('-')[0];
var n = S(e), i = {width: n.width, height: n.height}, r = -1 !== ['right', 'left'].indexOf(o),
p = r ? 'top' : 'left', s = r ? 'left' : 'top', d = r ? 'height' : 'width', a = r ? 'width' : 'height';
return i[p] = t[p] + t[d] / 2 - n[d] / 2, i[s] = o === s ? t[s] - n[a] : t[T(s)], i
}
function D(e, t) {
return Array.prototype.find ? e.find(t) : e.filter(t)[0]
}
function N(e, t, o) {
if (Array.prototype.findIndex) return e.findIndex(function (e) {
return e[t] === o
});
var n = D(e, function (e) {
return e[t] === o
});
return e.indexOf(n)
}
function P(t, o, n) {
var i = void 0 === n ? t : t.slice(0, N(t, 'name', n));
return i.forEach(function (t) {
t['function'] && console.warn('`modifier.function` is deprecated, use `modifier.fn`!');
var n = t['function'] || t.fn;
t.enabled && e(n) && (o.offsets.popper = g(o.offsets.popper), o.offsets.reference = g(o.offsets.reference), o = n(o, t))
}), o
}
function k() {
if (!this.state.isDestroyed) {
var e = {instance: this, styles: {}, arrowStyles: {}, attributes: {}, flipped: !1, offsets: {}};
e.offsets.reference = L(this.state, this.popper, this.reference, this.options.positionFixed), e.placement = O(this.options.placement, e.offsets.reference, this.popper, this.reference, this.options.modifiers.flip.boundariesElement, this.options.modifiers.flip.padding), e.originalPlacement = e.placement, e.positionFixed = this.options.positionFixed, e.offsets.popper = C(this.popper, e.offsets.reference, e.placement), e.offsets.popper.position = this.options.positionFixed ? 'fixed' : 'absolute', e = P(this.modifiers, e), this.state.isCreated ? this.options.onUpdate(e) : (this.state.isCreated = !0, this.options.onCreate(e))
}
}
function W(e, t) {
return e.some(function (e) {
var o = e.name, n = e.enabled;
return n && o === t
})
}
function B(e) {
for (var t = [!1, 'ms', 'Webkit', 'Moz', 'O'], o = e.charAt(0).toUpperCase() + e.slice(1), n = 0; n < t.length; n++) {
var i = t[n], r = i ? '' + i + o : e;
if ('undefined' != typeof document.body.style[r]) return r
}
return null
}
function H() {
return this.state.isDestroyed = !0, W(this.modifiers, 'applyStyle') && (this.popper.removeAttribute('x-placement'), this.popper.style.position = '', this.popper.style.top = '', this.popper.style.left = '', this.popper.style.right = '', this.popper.style.bottom = '', this.popper.style.willChange = '', this.popper.style[B('transform')] = ''), this.disableEventListeners(), this.options.removeOnDestroy && this.popper.parentNode.removeChild(this.popper), this
}
function A(e) {
var t = e.ownerDocument;
return t ? t.defaultView : window
}
function M(e, t, o, i) {
var r = 'BODY' === e.nodeName, p = r ? e.ownerDocument.defaultView : e;
p.addEventListener(t, o, {passive: !0}), r || M(n(p.parentNode), t, o, i), i.push(p)
}
function F(e, t, o, i) {
o.updateBound = i, A(e).addEventListener('resize', o.updateBound, {passive: !0});
var r = n(e);
return M(r, 'scroll', o.updateBound, o.scrollParents), o.scrollElement = r, o.eventsEnabled = !0, o
}
function I() {
this.state.eventsEnabled || (this.state = F(this.reference, this.options, this.state, this.scheduleUpdate))
}
function R(e, t) {
return A(e).removeEventListener('resize', t.updateBound), t.scrollParents.forEach(function (e) {
e.removeEventListener('scroll', t.updateBound)
}), t.updateBound = null, t.scrollParents = [], t.scrollElement = null, t.eventsEnabled = !1, t
}
function U() {
this.state.eventsEnabled && (cancelAnimationFrame(this.scheduleUpdate), this.state = R(this.reference, this.state))
}
function Y(e) {
return '' !== e && !isNaN(parseFloat(e)) && isFinite(e)
}
function V(e, t) {
Object.keys(t).forEach(function (o) {
var n = '';
-1 !== ['width', 'height', 'top', 'right', 'bottom', 'left'].indexOf(o) && Y(t[o]) && (n = 'px'), e.style[o] = t[o] + n
})
}
function j(e, t) {
Object.keys(t).forEach(function (o) {
var n = t[o];
!1 === n ? e.removeAttribute(o) : e.setAttribute(o, t[o])
})
}
function q(e, t) {
var o = e.offsets, n = o.popper, i = o.reference, r = $, p = function (e) {
return e
}, s = r(i.width), d = r(n.width), a = -1 !== ['left', 'right'].indexOf(e.placement),
l = -1 !== e.placement.indexOf('-'), f = t ? a || l || s % 2 == d % 2 ? r : Z : p, m = t ? r : p;
return {
left: f(1 == s % 2 && 1 == d % 2 && !l && t ? n.left - 1 : n.left),
top: m(n.top),
bottom: m(n.bottom),
right: f(n.right)
}
}
function K(e, t, o) {
var n = D(e, function (e) {
var o = e.name;
return o === t
}), i = !!n && e.some(function (e) {
return e.name === o && e.enabled && e.order < n.order
});
if (!i) {
var r = '`' + t + '`';
console.warn('`' + o + '`' + ' modifier is required by ' + r + ' modifier in order to work, be sure to include it before ' + r + '!')
}
return i
}
function z(e) {
return 'end' === e ? 'start' : 'start' === e ? 'end' : e
}
function G(e) {
var t = 1 < arguments.length && void 0 !== arguments[1] && arguments[1], o = he.indexOf(e),
n = he.slice(o + 1).concat(he.slice(0, o));
return t ? n.reverse() : n
}
function _(e, t, o, n) {
var i = e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/), r = +i[1], p = i[2];
if (!r) return e;
if (0 === p.indexOf('%')) {
var s;
switch (p) {
case'%p':
s = o;
break;
case'%':
case'%r':
default:
s = n;
}
var d = g(s);
return d[t] / 100 * r
}
if ('vh' === p || 'vw' === p) {
var a;
return a = 'vh' === p ? ee(document.documentElement.clientHeight, window.innerHeight || 0) : ee(document.documentElement.clientWidth, window.innerWidth || 0), a / 100 * r
}
return r
}
function X(e, t, o, n) {
var i = [0, 0], r = -1 !== ['right', 'left'].indexOf(n), p = e.split(/(\+|\-)/).map(function (e) {
return e.trim()
}), s = p.indexOf(D(p, function (e) {
return -1 !== e.search(/,|\s/)
}));
p[s] && -1 === p[s].indexOf(',') && console.warn('Offsets separated by white space(s) are deprecated, use a comma (,) instead.');
var d = /\s*,\s*|\s+/,
a = -1 === s ? [p] : [p.slice(0, s).concat([p[s].split(d)[0]]), [p[s].split(d)[1]].concat(p.slice(s + 1))];
return a = a.map(function (e, n) {
var i = (1 === n ? !r : r) ? 'height' : 'width', p = !1;
return e.reduce(function (e, t) {
return '' === e[e.length - 1] && -1 !== ['+', '-'].indexOf(t) ? (e[e.length - 1] = t, p = !0, e) : p ? (e[e.length - 1] += t, p = !1, e) : e.concat(t)
}, []).map(function (e) {
return _(e, i, t, o)
})
}), a.forEach(function (e, t) {
e.forEach(function (o, n) {
Y(o) && (i[t] += o * ('-' === e[n - 1] ? -1 : 1))
})
}), i
}
function J(e, t) {
var o, n = t.offset, i = e.placement, r = e.offsets, p = r.popper, s = r.reference, d = i.split('-')[0];
return o = Y(+n) ? [+n, 0] : X(n, p, s, d), 'left' === d ? (p.top += o[0], p.left -= o[1]) : 'right' === d ? (p.top += o[0], p.left += o[1]) : 'top' === d ? (p.left += o[0], p.top -= o[1]) : 'bottom' === d && (p.left += o[0], p.top += o[1]), e.popper = p, e
}
var Q = Math.min, Z = Math.floor, $ = Math.round, ee = Math.max,
te = 'undefined' != typeof window && 'undefined' != typeof document && 'undefined' != typeof navigator,
oe = function () {
for (var e = ['Edge', 'Trident', 'Firefox'], t = 0; t < e.length; t += 1) if (te && 0 <= navigator.userAgent.indexOf(e[t])) return 1;
return 0
}(), ne = te && window.Promise, ie = ne ? function (e) {
var t = !1;
return function () {
t || (t = !0, window.Promise.resolve().then(function () {
t = !1, e()
}))
}
} : function (e) {
var t = !1;
return function () {
t || (t = !0, setTimeout(function () {
t = !1, e()
}, oe))
}
}, re = te && !!(window.MSInputMethodContext && document.documentMode),
pe = te && /MSIE 10/.test(navigator.userAgent), se = function (e, t) {
if (!(e instanceof t)) throw new TypeError('Cannot call a class as a function')
}, de = function () {
function e(e, t) {
for (var o, n = 0; n < t.length; n++) o = t[n], o.enumerable = o.enumerable || !1, o.configurable = !0, 'value' in o && (o.writable = !0), Object.defineProperty(e, o.key, o)
}
return function (t, o, n) {
return o && e(t.prototype, o), n && e(t, n), t
}
}(), ae = function (e, t, o) {
return t in e ? Object.defineProperty(e, t, {
value: o,
enumerable: !0,
configurable: !0,
writable: !0
}) : e[t] = o, e
}, le = Object.assign || function (e) {
for (var t, o = 1; o < arguments.length; o++) for (var n in t = arguments[o], t) Object.prototype.hasOwnProperty.call(t, n) && (e[n] = t[n]);
return e
}, fe = te && /Firefox/i.test(navigator.userAgent),
me = ['auto-start', 'auto', 'auto-end', 'top-start', 'top', 'top-end', 'right-start', 'right', 'right-end', 'bottom-end', 'bottom', 'bottom-start', 'left-end', 'left', 'left-start'],
he = me.slice(3), ce = {FLIP: 'flip', CLOCKWISE: 'clockwise', COUNTERCLOCKWISE: 'counterclockwise'},
ge = function () {
function t(o, n) {
var i = this, r = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : {};
se(this, t), this.scheduleUpdate = function () {
return requestAnimationFrame(i.update)
}, this.update = ie(this.update.bind(this)), this.options = le({}, t.Defaults, r), this.state = {
isDestroyed: !1,
isCreated: !1,
scrollParents: []
}, this.reference = o && o.jquery ? o[0] : o, this.popper = n && n.jquery ? n[0] : n, this.options.modifiers = {}, Object.keys(le({}, t.Defaults.modifiers, r.modifiers)).forEach(function (e) {
i.options.modifiers[e] = le({}, t.Defaults.modifiers[e] || {}, r.modifiers ? r.modifiers[e] : {})
}), this.modifiers = Object.keys(this.options.modifiers).map(function (e) {
return le({name: e}, i.options.modifiers[e])
}).sort(function (e, t) {
return e.order - t.order
}), this.modifiers.forEach(function (t) {
t.enabled && e(t.onLoad) && t.onLoad(i.reference, i.popper, i.options, t, i.state)
}), this.update();
var p = this.options.eventsEnabled;
p && this.enableEventListeners(), this.state.eventsEnabled = p
}
return de(t, [{
key: 'update', value: function () {
return k.call(this)
}
}, {
key: 'destroy', value: function () {
return H.call(this)
}
}, {
key: 'enableEventListeners', value: function () {
return I.call(this)
}
}, {
key: 'disableEventListeners', value: function () {
return U.call(this)
}
}]), t
}();
return ge.Utils = ('undefined' == typeof window ? global : window).PopperUtils, ge.placements = me, ge.Defaults = {
placement: 'bottom', positionFixed: !1, eventsEnabled: !0, removeOnDestroy: !1, onCreate: function () {
}, onUpdate: function () {
}, modifiers: {
shift: {
order: 100, enabled: !0, fn: function (e) {
var t = e.placement, o = t.split('-')[0], n = t.split('-')[1];
if (n) {
var i = e.offsets, r = i.reference, p = i.popper, s = -1 !== ['bottom', 'top'].indexOf(o),
d = s ? 'left' : 'top', a = s ? 'width' : 'height',
l = {start: ae({}, d, r[d]), end: ae({}, d, r[d] + r[a] - p[a])};
e.offsets.popper = le({}, p, l[n])
}
return e
}
},
offset: {order: 200, enabled: !0, fn: J, offset: 0},
preventOverflow: {
order: 300, enabled: !0, fn: function (e, t) {
var o = t.boundariesElement || p(e.instance.popper);
e.instance.reference === o && (o = p(o));
var n = B('transform'), i = e.instance.popper.style, r = i.top, s = i.left, d = i[n];
i.top = '', i.left = '', i[n] = '';
var a = v(e.instance.popper, e.instance.reference, t.padding, o, e.positionFixed);
i.top = r, i.left = s, i[n] = d, t.boundaries = a;
var l = t.priority, f = e.offsets.popper, m = {
primary: function (e) {
var o = f[e];
return f[e] < a[e] && !t.escapeWithReference && (o = ee(f[e], a[e])), ae({}, e, o)
}, secondary: function (e) {
var o = 'right' === e ? 'left' : 'top', n = f[o];
return f[e] > a[e] && !t.escapeWithReference && (n = Q(f[o], a[e] - ('right' === e ? f.width : f.height))), ae({}, o, n)
}
};
return l.forEach(function (e) {
var t = -1 === ['left', 'top'].indexOf(e) ? 'secondary' : 'primary';
f = le({}, f, m[t](e))
}), e.offsets.popper = f, e
}, priority: ['left', 'right', 'top', 'bottom'], padding: 5, boundariesElement: 'scrollParent'
},
keepTogether: {
order: 400, enabled: !0, fn: function (e) {
var t = e.offsets, o = t.popper, n = t.reference, i = e.placement.split('-')[0], r = Z,
p = -1 !== ['top', 'bottom'].indexOf(i), s = p ? 'right' : 'bottom', d = p ? 'left' : 'top',
a = p ? 'width' : 'height';
return o[s] < r(n[d]) && (e.offsets.popper[d] = r(n[d]) - o[a]), o[d] > r(n[s]) && (e.offsets.popper[d] = r(n[s])), e
}
},
arrow: {
order: 500, enabled: !0, fn: function (e, o) {
var n;
if (!K(e.instance.modifiers, 'arrow', 'keepTogether')) return e;
var i = o.element;
if ('string' == typeof i) {
if (i = e.instance.popper.querySelector(i), !i) return e;
} else if (!e.instance.popper.contains(i)) return console.warn('WARNING: `arrow.element` must be child of its popper element!'), e;
var r = e.placement.split('-')[0], p = e.offsets, s = p.popper, d = p.reference,
a = -1 !== ['left', 'right'].indexOf(r), l = a ? 'height' : 'width', f = a ? 'Top' : 'Left',
m = f.toLowerCase(), h = a ? 'left' : 'top', c = a ? 'bottom' : 'right', u = S(i)[l];
d[c] - u < s[m] && (e.offsets.popper[m] -= s[m] - (d[c] - u)), d[m] + u > s[c] && (e.offsets.popper[m] += d[m] + u - s[c]), e.offsets.popper = g(e.offsets.popper);
var b = d[m] + d[l] / 2 - u / 2, w = t(e.instance.popper), y = parseFloat(w['margin' + f]),
E = parseFloat(w['border' + f + 'Width']), v = b - e.offsets.popper[m] - y - E;
return v = ee(Q(s[l] - u, v), 0), e.arrowElement = i, e.offsets.arrow = (n = {}, ae(n, m, $(v)), ae(n, h, ''), n), e
}, element: '[x-arrow]'
},
flip: {
order: 600,
enabled: !0,
fn: function (e, t) {
if (W(e.instance.modifiers, 'inner')) return e;
if (e.flipped && e.placement === e.originalPlacement) return e;
var o = v(e.instance.popper, e.instance.reference, t.padding, t.boundariesElement, e.positionFixed),
n = e.placement.split('-')[0], i = T(n), r = e.placement.split('-')[1] || '', p = [];
switch (t.behavior) {
case ce.FLIP:
p = [n, i];
break;
case ce.CLOCKWISE:
p = G(n);
break;
case ce.COUNTERCLOCKWISE:
p = G(n, !0);
break;
default:
p = t.behavior;
}
return p.forEach(function (s, d) {
if (n !== s || p.length === d + 1) return e;
n = e.placement.split('-')[0], i = T(n);
var a = e.offsets.popper, l = e.offsets.reference, f = Z,
m = 'left' === n && f(a.right) > f(l.left) || 'right' === n && f(a.left) < f(l.right) || 'top' === n && f(a.bottom) > f(l.top) || 'bottom' === n && f(a.top) < f(l.bottom),
h = f(a.left) < f(o.left), c = f(a.right) > f(o.right), g = f(a.top) < f(o.top),
u = f(a.bottom) > f(o.bottom),
b = 'left' === n && h || 'right' === n && c || 'top' === n && g || 'bottom' === n && u,
w = -1 !== ['top', 'bottom'].indexOf(n),
y = !!t.flipVariations && (w && 'start' === r && h || w && 'end' === r && c || !w && 'start' === r && g || !w && 'end' === r && u),
E = !!t.flipVariationsByContent && (w && 'start' === r && c || w && 'end' === r && h || !w && 'start' === r && u || !w && 'end' === r && g),
v = y || E;
(m || b || v) && (e.flipped = !0, (m || b) && (n = p[d + 1]), v && (r = z(r)), e.placement = n + (r ? '-' + r : ''), e.offsets.popper = le({}, e.offsets.popper, C(e.instance.popper, e.offsets.reference, e.placement)), e = P(e.instance.modifiers, e, 'flip'))
}), e
},
behavior: 'flip',
padding: 5,
boundariesElement: 'viewport',
flipVariations: !1,
flipVariationsByContent: !1
},
inner: {
order: 700, enabled: !1, fn: function (e) {
var t = e.placement, o = t.split('-')[0], n = e.offsets, i = n.popper, r = n.reference,
p = -1 !== ['left', 'right'].indexOf(o), s = -1 === ['top', 'left'].indexOf(o);
return i[p ? 'left' : 'top'] = r[o] - (s ? i[p ? 'width' : 'height'] : 0), e.placement = T(t), e.offsets.popper = g(i), e
}
},
hide: {
order: 800, enabled: !0, fn: function (e) {
if (!K(e.instance.modifiers, 'hide', 'preventOverflow')) return e;
var t = e.offsets.reference, o = D(e.instance.modifiers, function (e) {
return 'preventOverflow' === e.name
}).boundaries;
if (t.bottom < o.top || t.left > o.right || t.top > o.bottom || t.right < o.left) {
if (!0 === e.hide) return e;
e.hide = !0, e.attributes['x-out-of-boundaries'] = ''
} else {
if (!1 === e.hide) return e;
e.hide = !1, e.attributes['x-out-of-boundaries'] = !1
}
return e
}
},
computeStyle: {
order: 850, enabled: !0, fn: function (e, t) {
var o = t.x, n = t.y, i = e.offsets.popper, r = D(e.instance.modifiers, function (e) {
return 'applyStyle' === e.name
}).gpuAcceleration;
void 0 !== r && console.warn('WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!');
var s, d, a = void 0 === r ? t.gpuAcceleration : r, l = p(e.instance.popper), f = u(l),
m = {position: i.position}, h = q(e, 2 > window.devicePixelRatio || !fe),
c = 'bottom' === o ? 'top' : 'bottom', g = 'right' === n ? 'left' : 'right', b = B('transform');
if (d = 'bottom' == c ? 'HTML' === l.nodeName ? -l.clientHeight + h.bottom : -f.height + h.bottom : h.top, s = 'right' == g ? 'HTML' === l.nodeName ? -l.clientWidth + h.right : -f.width + h.right : h.left, a && b) m[b] = 'translate3d(' + s + 'px, ' + d + 'px, 0)', m[c] = 0, m[g] = 0, m.willChange = 'transform'; else {
var w = 'bottom' == c ? -1 : 1, y = 'right' == g ? -1 : 1;
m[c] = d * w, m[g] = s * y, m.willChange = c + ', ' + g
}
var E = {"x-placement": e.placement};
return e.attributes = le({}, E, e.attributes), e.styles = le({}, m, e.styles), e.arrowStyles = le({}, e.offsets.arrow, e.arrowStyles), e
}, gpuAcceleration: !0, x: 'bottom', y: 'right'
},
applyStyle: {
order: 900, enabled: !0, fn: function (e) {
return V(e.instance.popper, e.styles), j(e.instance.popper, e.attributes), e.arrowElement && Object.keys(e.arrowStyles).length && V(e.arrowElement, e.arrowStyles), e
}, onLoad: function (e, t, o, n, i) {
var r = L(i, t, e, o.positionFixed),
p = O(o.placement, r, t, e, o.modifiers.flip.boundariesElement, o.modifiers.flip.padding);
return t.setAttribute('x-placement', p), V(t, {position: o.positionFixed ? 'fixed' : 'absolute'}), o
}, gpuAcceleration: void 0
}
}
}, ge
});
//# sourceMappingURL=popper.min.js.map
/*!
* Bootstrap v4.5.3 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
!function (t, e) {
"object" == typeof exports && "undefined" != typeof module ? e(exports, require("jquery"), require("popper.js")) : "function" == typeof define && define.amd ? define(["exports", "jquery", "popper.js"], e) : e((t = "undefined" != typeof globalThis ? globalThis : t || self).bootstrap = {}, t.jQuery, t.Popper)
}(this, (function (t, e, n) {
"use strict";
function i(t) {
return t && "object" == typeof t && "default" in t ? t : {
default: t
}
}
var o = i(e),
a = i(n);
function s(t, e) {
for (var n = 0; n < e.length; n++) {
var i = e[n];
i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(t, i.key, i)
}
}
function l(t, e, n) {
return e && s(t.prototype, e), n && s(t, n), t
}
function r() {
return (r = Object.assign || function (t) {
for (var e = 1; e < arguments.length; e++) {
var n = arguments[e];
for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (t[i] = n[i])
}
return t
}).apply(this, arguments)
}
function u(t) {
var e = this,
n = !1;
return o.default(this).one(d.TRANSITION_END, (function () {
n = !0
})), setTimeout((function () {
n || d.triggerTransitionEnd(e)
}), t), this
}
var d = {
TRANSITION_END: "bsTransitionEnd",
getUID: function (t) {
do {
t += ~~(1e6 * Math.random())
} while (document.getElementById(t));
return t
},
getSelectorFromElement: function (t) {
var e = t.getAttribute("data-target");
if (!e || "#" === e) {
var n = t.getAttribute("href");
e = n && "#" !== n ? n.trim() : ""
}
try {
return document.querySelector(e) ? e : null
} catch (t) {
return null
}
},
getTransitionDurationFromElement: function (t) {
if (!t) return 0;
var e = o.default(t).css("transition-duration"),
n = o.default(t).css("transition-delay"),
i = parseFloat(e),
a = parseFloat(n);
return i || a ? (e = e.split(",")[0], n = n.split(",")[0], 1e3 * (parseFloat(e) + parseFloat(n))) : 0
},
reflow: function (t) {
return t.offsetHeight
},
triggerTransitionEnd: function (t) {
o.default(t).trigger("transitionend")
},
supportsTransitionEnd: function () {
return Boolean("transitionend")
},
isElement: function (t) {
return (t[0] || t).nodeType
},
typeCheckConfig: function (t, e, n) {
for (var i in n)
if (Object.prototype.hasOwnProperty.call(n, i)) {
var o = n[i],
a = e[i],
s = a && d.isElement(a) ? "element" : null === (l = a) || "undefined" == typeof l ? "" + l : {}.toString.call(l).match(/\s([a-z]+)/i)[1].toLowerCase();
if (!new RegExp(o).test(s)) throw new Error(t.toUpperCase() + ': Option "' + i + '" provided type "' + s + '" but expected type "' + o + '".')
}
var l
},
findShadowRoot: function (t) {
if (!document.documentElement.attachShadow) return null;
if ("function" == typeof t.getRootNode) {
var e = t.getRootNode();
return e instanceof ShadowRoot ? e : null
}
return t instanceof ShadowRoot ? t : t.parentNode ? d.findShadowRoot(t.parentNode) : null
},
jQueryDetection: function () {
if ("undefined" == typeof o.default) throw new TypeError("Bootstrap's JavaScript requires jQuery. jQuery must be included before Bootstrap's JavaScript.");
var t = o.default.fn.jquery.split(" ")[0].split(".");
if (t[0] < 2 && t[1] < 9 || 1 === t[0] && 9 === t[1] && t[2] < 1 || t[0] >= 4) throw new Error("Bootstrap's JavaScript requires at least jQuery v1.9.1 but less than v4.0.0")
}
};
d.jQueryDetection(), o.default.fn.emulateTransitionEnd = u, o.default.event.special[d.TRANSITION_END] = {
bindType: "transitionend",
delegateType: "transitionend",
handle: function (t) {
if (o.default(t.target).is(this)) return t.handleObj.handler.apply(this, arguments)
}
};
var f = "alert",
c = o.default.fn[f],
h = function () {
function t(t) {
this._element = t
}
var e = t.prototype;
return e.close = function (t) {
var e = this._element;
t && (e = this._getRootElement(t)), this._triggerCloseEvent(e).isDefaultPrevented() || this._removeElement(e)
}, e.dispose = function () {
o.default.removeData(this._element, "bs.alert"), this._element = null
}, e._getRootElement = function (t) {
var e = d.getSelectorFromElement(t),
n = !1;
return e && (n = document.querySelector(e)), n || (n = o.default(t).closest(".alert")[0]), n
}, e._triggerCloseEvent = function (t) {
var e = o.default.Event("close.bs.alert");
return o.default(t).trigger(e), e
}, e._removeElement = function (t) {
var e = this;
if (o.default(t).removeClass("show"), o.default(t).hasClass("fade")) {
var n = d.getTransitionDurationFromElement(t);
o.default(t).one(d.TRANSITION_END, (function (n) {
return e._destroyElement(t, n)
})).emulateTransitionEnd(n)
} else this._destroyElement(t)
}, e._destroyElement = function (t) {
o.default(t).detach().trigger("closed.bs.alert").remove()
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this),
i = n.data("bs.alert");
i || (i = new t(this), n.data("bs.alert", i)), "close" === e && i[e](this)
}))
}, t._handleDismiss = function (t) {
return function (e) {
e && e.preventDefault(), t.close(this)
}
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}]), t
}();
o.default(document).on("click.bs.alert.data-api", '[data-dismiss="alert"]', h._handleDismiss(new h)), o.default.fn[f] = h._jQueryInterface, o.default.fn[f].Constructor = h, o.default.fn[f].noConflict = function () {
return o.default.fn[f] = c, h._jQueryInterface
};
var g = o.default.fn.button,
m = function () {
function t(t) {
this._element = t, this.shouldAvoidTriggerChange = !1
}
var e = t.prototype;
return e.toggle = function () {
var t = !0,
e = !0,
n = o.default(this._element).closest('[data-toggle="buttons"]')[0];
if (n) {
var i = this._element.querySelector('input:not([type="hidden"])');
if (i) {
if ("radio" === i.type)
if (i.checked && this._element.classList.contains("active")) t = !1;
else {
var a = n.querySelector(".active");
a && o.default(a).removeClass("active")
}
t && ("checkbox" !== i.type && "radio" !== i.type || (i.checked = !this._element.classList.contains("active")), this.shouldAvoidTriggerChange || o.default(i).trigger("change")), i.focus(), e = !1
}
}
this._element.hasAttribute("disabled") || this._element.classList.contains("disabled") || (e && this._element.setAttribute("aria-pressed", !this._element.classList.contains("active")), t && o.default(this._element).toggleClass("active"))
}, e.dispose = function () {
o.default.removeData(this._element, "bs.button"), this._element = null
}, t._jQueryInterface = function (e, n) {
return this.each((function () {
var i = o.default(this),
a = i.data("bs.button");
a || (a = new t(this), i.data("bs.button", a)), a.shouldAvoidTriggerChange = n, "toggle" === e && a[e]()
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}]), t
}();
o.default(document).on("click.bs.button.data-api", '[data-toggle^="button"]', (function (t) {
var e = t.target,
n = e;
if (o.default(e).hasClass("btn") || (e = o.default(e).closest(".btn")[0]), !e || e.hasAttribute("disabled") || e.classList.contains("disabled")) t.preventDefault();
else {
var i = e.querySelector('input:not([type="hidden"])');
if (i && (i.hasAttribute("disabled") || i.classList.contains("disabled"))) return void t.preventDefault();
"INPUT" !== n.tagName && "LABEL" === e.tagName || m._jQueryInterface.call(o.default(e), "toggle", "INPUT" === n.tagName)
}
})).on("focus.bs.button.data-api blur.bs.button.data-api", '[data-toggle^="button"]', (function (t) {
var e = o.default(t.target).closest(".btn")[0];
o.default(e).toggleClass("focus", /^focus(in)?$/.test(t.type))
})), o.default(window).on("load.bs.button.data-api", (function () {
for (var t = [].slice.call(document.querySelectorAll('[data-toggle="buttons"] .btn')), e = 0, n = t.length; e < n; e++) {
var i = t[e],
o = i.querySelector('input:not([type="hidden"])');
o.checked || o.hasAttribute("checked") ? i.classList.add("active") : i.classList.remove("active")
}
for (var a = 0, s = (t = [].slice.call(document.querySelectorAll('[data-toggle="button"]'))).length; a < s; a++) {
var l = t[a];
"true" === l.getAttribute("aria-pressed") ? l.classList.add("active") : l.classList.remove("active")
}
})), o.default.fn.button = m._jQueryInterface, o.default.fn.button.Constructor = m, o.default.fn.button.noConflict = function () {
return o.default.fn.button = g, m._jQueryInterface
};
var p = "carousel",
_ = ".bs.carousel",
v = o.default.fn[p],
b = {
interval: 5e3,
keyboard: !0,
slide: !1,
pause: "hover",
wrap: !0,
touch: !0
},
y = {
interval: "(number|boolean)",
keyboard: "boolean",
slide: "(boolean|string)",
pause: "(string|boolean)",
wrap: "boolean",
touch: "boolean"
},
E = {
TOUCH: "touch",
PEN: "pen"
},
w = function () {
function t(t, e) {
this._items = null, this._interval = null, this._activeElement = null, this._isPaused = !1, this._isSliding = !1, this.touchTimeout = null, this.touchStartX = 0, this.touchDeltaX = 0, this._config = this._getConfig(e), this._element = t, this._indicatorsElement = this._element.querySelector(".carousel-indicators"), this._touchSupported = "ontouchstart" in document.documentElement || navigator.maxTouchPoints > 0, this._pointerEvent = Boolean(window.PointerEvent || window.MSPointerEvent), this._addEventListeners()
}
var e = t.prototype;
return e.next = function () {
this._isSliding || this._slide("next")
}, e.nextWhenVisible = function () {
var t = o.default(this._element);
!document.hidden && t.is(":visible") && "hidden" !== t.css("visibility") && this.next()
}, e.prev = function () {
this._isSliding || this._slide("prev")
}, e.pause = function (t) {
t || (this._isPaused = !0), this._element.querySelector(".carousel-item-next, .carousel-item-prev") && (d.triggerTransitionEnd(this._element), this.cycle(!0)), clearInterval(this._interval), this._interval = null
}, e.cycle = function (t) {
t || (this._isPaused = !1), this._interval && (clearInterval(this._interval), this._interval = null), this._config.interval && !this._isPaused && (this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval))
}, e.to = function (t) {
var e = this;
this._activeElement = this._element.querySelector(".active.carousel-item");
var n = this._getItemIndex(this._activeElement);
if (!(t > this._items.length - 1 || t < 0))
if (this._isSliding) o.default(this._element).one("slid.bs.carousel", (function () {
return e.to(t)
}));
else {
if (n === t) return this.pause(), void this.cycle();
var i = t > n ? "next" : "prev";
this._slide(i, this._items[t])
}
}, e.dispose = function () {
o.default(this._element).off(_), o.default.removeData(this._element, "bs.carousel"), this._items = null, this._config = null, this._element = null, this._interval = null, this._isPaused = null, this._isSliding = null, this._activeElement = null, this._indicatorsElement = null
}, e._getConfig = function (t) {
return t = r({}, b, t), d.typeCheckConfig(p, t, y), t
}, e._handleSwipe = function () {
var t = Math.abs(this.touchDeltaX);
if (!(t <= 40)) {
var e = t / this.touchDeltaX;
this.touchDeltaX = 0, e > 0 && this.prev(), e < 0 && this.next()
}
}, e._addEventListeners = function () {
var t = this;
this._config.keyboard && o.default(this._element).on("keydown.bs.carousel", (function (e) {
return t._keydown(e)
})), "hover" === this._config.pause && o.default(this._element).on("mouseenter.bs.carousel", (function (e) {
return t.pause(e)
})).on("mouseleave.bs.carousel", (function (e) {
return t.cycle(e)
})), this._config.touch && this._addTouchEventListeners()
}, e._addTouchEventListeners = function () {
var t = this;
if (this._touchSupported) {
var e = function (e) {
t._pointerEvent && E[e.originalEvent.pointerType.toUpperCase()] ? t.touchStartX = e.originalEvent.clientX : t._pointerEvent || (t.touchStartX = e.originalEvent.touches[0].clientX)
},
n = function (e) {
t._pointerEvent && E[e.originalEvent.pointerType.toUpperCase()] && (t.touchDeltaX = e.originalEvent.clientX - t.touchStartX), t._handleSwipe(), "hover" === t._config.pause && (t.pause(), t.touchTimeout && clearTimeout(t.touchTimeout), t.touchTimeout = setTimeout((function (e) {
return t.cycle(e)
}), 500 + t._config.interval))
};
o.default(this._element.querySelectorAll(".carousel-item img")).on("dragstart.bs.carousel", (function (t) {
return t.preventDefault()
})), this._pointerEvent ? (o.default(this._element).on("pointerdown.bs.carousel", (function (t) {
return e(t)
})), o.default(this._element).on("pointerup.bs.carousel", (function (t) {
return n(t)
})), this._element.classList.add("pointer-event")) : (o.default(this._element).on("touchstart.bs.carousel", (function (t) {
return e(t)
})), o.default(this._element).on("touchmove.bs.carousel", (function (e) {
return function (e) {
e.originalEvent.touches && e.originalEvent.touches.length > 1 ? t.touchDeltaX = 0 : t.touchDeltaX = e.originalEvent.touches[0].clientX - t.touchStartX
}(e)
})), o.default(this._element).on("touchend.bs.carousel", (function (t) {
return n(t)
})))
}
}, e._keydown = function (t) {
if (!/input|textarea/i.test(t.target.tagName)) switch (t.which) {
case 37:
t.preventDefault(), this.prev();
break;
case 39:
t.preventDefault(), this.next()
}
}, e._getItemIndex = function (t) {
return this._items = t && t.parentNode ? [].slice.call(t.parentNode.querySelectorAll(".carousel-item")) : [], this._items.indexOf(t)
}, e._getItemByDirection = function (t, e) {
var n = "next" === t,
i = "prev" === t,
o = this._getItemIndex(e),
a = this._items.length - 1;
if ((i && 0 === o || n && o === a) && !this._config.wrap) return e;
var s = (o + ("prev" === t ? -1 : 1)) % this._items.length;
return -1 === s ? this._items[this._items.length - 1] : this._items[s]
}, e._triggerSlideEvent = function (t, e) {
var n = this._getItemIndex(t),
i = this._getItemIndex(this._element.querySelector(".active.carousel-item")),
a = o.default.Event("slide.bs.carousel", {
relatedTarget: t,
direction: e,
from: i,
to: n
});
return o.default(this._element).trigger(a), a
}, e._setActiveIndicatorElement = function (t) {
if (this._indicatorsElement) {
var e = [].slice.call(this._indicatorsElement.querySelectorAll(".active"));
o.default(e).removeClass("active");
var n = this._indicatorsElement.children[this._getItemIndex(t)];
n && o.default(n).addClass("active")
}
}, e._slide = function (t, e) {
var n, i, a, s = this,
l = this._element.querySelector(".active.carousel-item"),
r = this._getItemIndex(l),
u = e || l && this._getItemByDirection(t, l),
f = this._getItemIndex(u),
c = Boolean(this._interval);
if ("next" === t ? (n = "carousel-item-left", i = "carousel-item-next", a = "left") : (n = "carousel-item-right", i = "carousel-item-prev", a = "right"), u && o.default(u).hasClass("active")) this._isSliding = !1;
else if (!this._triggerSlideEvent(u, a).isDefaultPrevented() && l && u) {
this._isSliding = !0, c && this.pause(), this._setActiveIndicatorElement(u);
var h = o.default.Event("slid.bs.carousel", {
relatedTarget: u,
direction: a,
from: r,
to: f
});
if (o.default(this._element).hasClass("slide")) {
o.default(u).addClass(i), d.reflow(u), o.default(l).addClass(n), o.default(u).addClass(n);
var g = parseInt(u.getAttribute("data-interval"), 10);
g ? (this._config.defaultInterval = this._config.defaultInterval || this._config.interval, this._config.interval = g) : this._config.interval = this._config.defaultInterval || this._config.interval;
var m = d.getTransitionDurationFromElement(l);
o.default(l).one(d.TRANSITION_END, (function () {
o.default(u).removeClass(n + " " + i).addClass("active"), o.default(l).removeClass("active " + i + " " + n), s._isSliding = !1, setTimeout((function () {
return o.default(s._element).trigger(h)
}), 0)
})).emulateTransitionEnd(m)
} else o.default(l).removeClass("active"), o.default(u).addClass("active"), this._isSliding = !1, o.default(this._element).trigger(h);
c && this.cycle()
}
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this).data("bs.carousel"),
i = r({}, b, o.default(this).data());
"object" == typeof e && (i = r({}, i, e));
var a = "string" == typeof e ? e : i.slide;
if (n || (n = new t(this, i), o.default(this).data("bs.carousel", n)), "number" == typeof e) n.to(e);
else if ("string" == typeof a) {
if ("undefined" == typeof n[a]) throw new TypeError('No method named "' + a + '"');
n[a]()
} else i.interval && i.ride && (n.pause(), n.cycle())
}))
}, t._dataApiClickHandler = function (e) {
var n = d.getSelectorFromElement(this);
if (n) {
var i = o.default(n)[0];
if (i && o.default(i).hasClass("carousel")) {
var a = r({}, o.default(i).data(), o.default(this).data()),
s = this.getAttribute("data-slide-to");
s && (a.interval = !1), t._jQueryInterface.call(o.default(i), a), s && o.default(i).data("bs.carousel").to(s), e.preventDefault()
}
}
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return b
}
}]), t
}();
o.default(document).on("click.bs.carousel.data-api", "[data-slide], [data-slide-to]", w._dataApiClickHandler), o.default(window).on("load.bs.carousel.data-api", (function () {
for (var t = [].slice.call(document.querySelectorAll('[data-ride="carousel"]')), e = 0, n = t.length; e < n; e++) {
var i = o.default(t[e]);
w._jQueryInterface.call(i, i.data())
}
})), o.default.fn[p] = w._jQueryInterface, o.default.fn[p].Constructor = w, o.default.fn[p].noConflict = function () {
return o.default.fn[p] = v, w._jQueryInterface
};
var T = "collapse",
C = o.default.fn[T],
S = {
toggle: !0,
parent: ""
},
N = {
toggle: "boolean",
parent: "(string|element)"
},
D = function () {
function t(t, e) {
this._isTransitioning = !1, this._element = t, this._config = this._getConfig(e), this._triggerArray = [].slice.call(document.querySelectorAll('[data-toggle="collapse"][href="#' + t.id + '"],[data-toggle="collapse"][data-target="#' + t.id + '"]'));
for (var n = [].slice.call(document.querySelectorAll('[data-toggle="collapse"]')), i = 0, o = n.length; i < o; i++) {
var a = n[i],
s = d.getSelectorFromElement(a),
l = [].slice.call(document.querySelectorAll(s)).filter((function (e) {
return e === t
}));
null !== s && l.length > 0 && (this._selector = s, this._triggerArray.push(a))
}
this._parent = this._config.parent ? this._getParent() : null, this._config.parent || this._addAriaAndCollapsedClass(this._element, this._triggerArray), this._config.toggle && this.toggle()
}
var e = t.prototype;
return e.toggle = function () {
o.default(this._element).hasClass("show") ? this.hide() : this.show()
}, e.show = function () {
var e, n, i = this;
if (!this._isTransitioning && !o.default(this._element).hasClass("show") && (this._parent && 0 === (e = [].slice.call(this._parent.querySelectorAll(".show, .collapsing")).filter((function (t) {
return "string" == typeof i._config.parent ? t.getAttribute("data-parent") === i._config.parent : t.classList.contains("collapse")
}))).length && (e = null), !(e && (n = o.default(e).not(this._selector).data("bs.collapse")) && n._isTransitioning))) {
var a = o.default.Event("show.bs.collapse");
if (o.default(this._element).trigger(a), !a.isDefaultPrevented()) {
e && (t._jQueryInterface.call(o.default(e).not(this._selector), "hide"), n || o.default(e).data("bs.collapse", null));
var s = this._getDimension();
o.default(this._element).removeClass("collapse").addClass("collapsing"), this._element.style[s] = 0, this._triggerArray.length && o.default(this._triggerArray).removeClass("collapsed").attr("aria-expanded", !0), this.setTransitioning(!0);
var l = "scroll" + (s[0].toUpperCase() + s.slice(1)),
r = d.getTransitionDurationFromElement(this._element);
o.default(this._element).one(d.TRANSITION_END, (function () {
o.default(i._element).removeClass("collapsing").addClass("collapse show"), i._element.style[s] = "", i.setTransitioning(!1), o.default(i._element).trigger("shown.bs.collapse")
})).emulateTransitionEnd(r), this._element.style[s] = this._element[l] + "px"
}
}
}, e.hide = function () {
var t = this;
if (!this._isTransitioning && o.default(this._element).hasClass("show")) {
var e = o.default.Event("hide.bs.collapse");
if (o.default(this._element).trigger(e), !e.isDefaultPrevented()) {
var n = this._getDimension();
this._element.style[n] = this._element.getBoundingClientRect()[n] + "px", d.reflow(this._element), o.default(this._element).addClass("collapsing").removeClass("collapse show");
var i = this._triggerArray.length;
if (i > 0)
for (var a = 0; a < i; a++) {
var s = this._triggerArray[a],
l = d.getSelectorFromElement(s);
if (null !== l) o.default([].slice.call(document.querySelectorAll(l))).hasClass("show") || o.default(s).addClass("collapsed").attr("aria-expanded", !1)
}
this.setTransitioning(!0);
this._element.style[n] = "";
var r = d.getTransitionDurationFromElement(this._element);
o.default(this._element).one(d.TRANSITION_END, (function () {
t.setTransitioning(!1), o.default(t._element).removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")
})).emulateTransitionEnd(r)
}
}
}, e.setTransitioning = function (t) {
this._isTransitioning = t
}, e.dispose = function () {
o.default.removeData(this._element, "bs.collapse"), this._config = null, this._parent = null, this._element = null, this._triggerArray = null, this._isTransitioning = null
}, e._getConfig = function (t) {
return (t = r({}, S, t)).toggle = Boolean(t.toggle), d.typeCheckConfig(T, t, N), t
}, e._getDimension = function () {
return o.default(this._element).hasClass("width") ? "width" : "height"
}, e._getParent = function () {
var e, n = this;
d.isElement(this._config.parent) ? (e = this._config.parent, "undefined" != typeof this._config.parent.jquery && (e = this._config.parent[0])) : e = document.querySelector(this._config.parent);
var i = '[data-toggle="collapse"][data-parent="' + this._config.parent + '"]',
a = [].slice.call(e.querySelectorAll(i));
return o.default(a).each((function (e, i) {
n._addAriaAndCollapsedClass(t._getTargetFromElement(i), [i])
})), e
}, e._addAriaAndCollapsedClass = function (t, e) {
var n = o.default(t).hasClass("show");
e.length && o.default(e).toggleClass("collapsed", !n).attr("aria-expanded", n)
}, t._getTargetFromElement = function (t) {
var e = d.getSelectorFromElement(t);
return e ? document.querySelector(e) : null
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this),
i = n.data("bs.collapse"),
a = r({}, S, n.data(), "object" == typeof e && e ? e : {});
if (!i && a.toggle && "string" == typeof e && /show|hide/.test(e) && (a.toggle = !1), i || (i = new t(this, a), n.data("bs.collapse", i)), "string" == typeof e) {
if ("undefined" == typeof i[e]) throw new TypeError('No method named "' + e + '"');
i[e]()
}
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return S
}
}]), t
}();
o.default(document).on("click.bs.collapse.data-api", '[data-toggle="collapse"]', (function (t) {
"A" === t.currentTarget.tagName && t.preventDefault();
var e = o.default(this),
n = d.getSelectorFromElement(this),
i = [].slice.call(document.querySelectorAll(n));
o.default(i).each((function () {
var t = o.default(this),
n = t.data("bs.collapse") ? "toggle" : e.data();
D._jQueryInterface.call(t, n)
}))
})), o.default.fn[T] = D._jQueryInterface, o.default.fn[T].Constructor = D, o.default.fn[T].noConflict = function () {
return o.default.fn[T] = C, D._jQueryInterface
};
var k = "dropdown",
A = o.default.fn[k],
I = new RegExp("38|40|27"),
j = {
offset: 0,
flip: !0,
boundary: "scrollParent",
reference: "toggle",
display: "dynamic",
popperConfig: null
},
O = {
offset: "(number|string|function)",
flip: "boolean",
boundary: "(string|element)",
reference: "(string|element)",
display: "string",
popperConfig: "(null|object)"
},
x = function () {
function t(t, e) {
this._element = t, this._popper = null, this._config = this._getConfig(e), this._menu = this._getMenuElement(), this._inNavbar = this._detectNavbar(), this._addEventListeners()
}
var e = t.prototype;
return e.toggle = function () {
if (!this._element.disabled && !o.default(this._element).hasClass("disabled")) {
var e = o.default(this._menu).hasClass("show");
t._clearMenus(), e || this.show(!0)
}
}, e.show = function (e) {
if (void 0 === e && (e = !1), !(this._element.disabled || o.default(this._element).hasClass("disabled") || o.default(this._menu).hasClass("show"))) {
var n = {
relatedTarget: this._element
},
i = o.default.Event("show.bs.dropdown", n),
s = t._getParentFromElement(this._element);
if (o.default(s).trigger(i), !i.isDefaultPrevented()) {
if (!this._inNavbar && e) {
if ("undefined" == typeof a.default) throw new TypeError("Bootstrap's dropdowns require Popper.js (https://popper.js.org/)");
var l = this._element;
"parent" === this._config.reference ? l = s : d.isElement(this._config.reference) && (l = this._config.reference, "undefined" != typeof this._config.reference.jquery && (l = this._config.reference[0])), "scrollParent" !== this._config.boundary && o.default(s).addClass("position-static"), this._popper = new a.default(l, this._menu, this._getPopperConfig())
}
"ontouchstart" in document.documentElement && 0 === o.default(s).closest(".navbar-nav").length && o.default(document.body).children().on("mouseover", null, o.default.noop), this._element.focus(), this._element.setAttribute("aria-expanded", !0), o.default(this._menu).toggleClass("show"), o.default(s).toggleClass("show").trigger(o.default.Event("shown.bs.dropdown", n))
}
}
}, e.hide = function () {
if (!this._element.disabled && !o.default(this._element).hasClass("disabled") && o.default(this._menu).hasClass("show")) {
var e = {
relatedTarget: this._element
},
n = o.default.Event("hide.bs.dropdown", e),
i = t._getParentFromElement(this._element);
o.default(i).trigger(n), n.isDefaultPrevented() || (this._popper && this._popper.destroy(), o.default(this._menu).toggleClass("show"), o.default(i).toggleClass("show").trigger(o.default.Event("hidden.bs.dropdown", e)))
}
}, e.dispose = function () {
o.default.removeData(this._element, "bs.dropdown"), o.default(this._element).off(".bs.dropdown"), this._element = null, this._menu = null, null !== this._popper && (this._popper.destroy(), this._popper = null)
}, e.update = function () {
this._inNavbar = this._detectNavbar(), null !== this._popper && this._popper.scheduleUpdate()
}, e._addEventListeners = function () {
var t = this;
o.default(this._element).on("click.bs.dropdown", (function (e) {
e.preventDefault(), e.stopPropagation(), t.toggle()
}))
}, e._getConfig = function (t) {
return t = r({}, this.constructor.Default, o.default(this._element).data(), t), d.typeCheckConfig(k, t, this.constructor.DefaultType), t
}, e._getMenuElement = function () {
if (!this._menu) {
var e = t._getParentFromElement(this._element);
e && (this._menu = e.querySelector(".dropdown-menu"))
}
return this._menu
}, e._getPlacement = function () {
var t = o.default(this._element.parentNode),
e = "bottom-start";
return t.hasClass("dropup") ? e = o.default(this._menu).hasClass("dropdown-menu-right") ? "top-end" : "top-start" : t.hasClass("dropright") ? e = "right-start" : t.hasClass("dropleft") ? e = "left-start" : o.default(this._menu).hasClass("dropdown-menu-right") && (e = "bottom-end"), e
}, e._detectNavbar = function () {
return o.default(this._element).closest(".navbar").length > 0
}, e._getOffset = function () {
var t = this,
e = {};
return "function" == typeof this._config.offset ? e.fn = function (e) {
return e.offsets = r({}, e.offsets, t._config.offset(e.offsets, t._element) || {}), e
} : e.offset = this._config.offset, e
}, e._getPopperConfig = function () {
var t = {
placement: this._getPlacement(),
modifiers: {
offset: this._getOffset(),
flip: {
enabled: this._config.flip
},
preventOverflow: {
boundariesElement: this._config.boundary
}
}
};
return "static" === this._config.display && (t.modifiers.applyStyle = {
enabled: !1
}), r({}, t, this._config.popperConfig)
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this).data("bs.dropdown");
if (n || (n = new t(this, "object" == typeof e ? e : null), o.default(this).data("bs.dropdown", n)), "string" == typeof e) {
if ("undefined" == typeof n[e]) throw new TypeError('No method named "' + e + '"');
n[e]()
}
}))
}, t._clearMenus = function (e) {
if (!e || 3 !== e.which && ("keyup" !== e.type || 9 === e.which))
for (var n = [].slice.call(document.querySelectorAll('[data-toggle="dropdown"]')), i = 0, a = n.length; i < a; i++) {
var s = t._getParentFromElement(n[i]),
l = o.default(n[i]).data("bs.dropdown"),
r = {
relatedTarget: n[i]
};
if (e && "click" === e.type && (r.clickEvent = e), l) {
var u = l._menu;
if (o.default(s).hasClass("show") && !(e && ("click" === e.type && /input|textarea/i.test(e.target.tagName) || "keyup" === e.type && 9 === e.which) && o.default.contains(s, e.target))) {
var d = o.default.Event("hide.bs.dropdown", r);
o.default(s).trigger(d), d.isDefaultPrevented() || ("ontouchstart" in document.documentElement && o.default(document.body).children().off("mouseover", null, o.default.noop), n[i].setAttribute("aria-expanded", "false"), l._popper && l._popper.destroy(), o.default(u).removeClass("show"), o.default(s).removeClass("show").trigger(o.default.Event("hidden.bs.dropdown", r)))
}
}
}
}, t._getParentFromElement = function (t) {
var e, n = d.getSelectorFromElement(t);
return n && (e = document.querySelector(n)), e || t.parentNode
}, t._dataApiKeydownHandler = function (e) {
if (!(/input|textarea/i.test(e.target.tagName) ? 32 === e.which || 27 !== e.which && (40 !== e.which && 38 !== e.which || o.default(e.target).closest(".dropdown-menu").length) : !I.test(e.which)) && !this.disabled && !o.default(this).hasClass("disabled")) {
var n = t._getParentFromElement(this),
i = o.default(n).hasClass("show");
if (i || 27 !== e.which) {
if (e.preventDefault(), e.stopPropagation(), !i || 27 === e.which || 32 === e.which) return 27 === e.which && o.default(n.querySelector('[data-toggle="dropdown"]')).trigger("focus"), void o.default(this).trigger("click");
var a = [].slice.call(n.querySelectorAll(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)")).filter((function (t) {
return o.default(t).is(":visible")
}));
if (0 !== a.length) {
var s = a.indexOf(e.target);
38 === e.which && s > 0 && s--, 40 === e.which && s < a.length - 1 && s++, s < 0 && (s = 0), a[s].focus()
}
}
}
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return j
}
}, {
key: "DefaultType",
get: function () {
return O
}
}]), t
}();
o.default(document).on("keydown.bs.dropdown.data-api", '[data-toggle="dropdown"]', x._dataApiKeydownHandler).on("keydown.bs.dropdown.data-api", ".dropdown-menu", x._dataApiKeydownHandler).on("click.bs.dropdown.data-api keyup.bs.dropdown.data-api", x._clearMenus).on("click.bs.dropdown.data-api", '[data-toggle="dropdown"]', (function (t) {
t.preventDefault(), t.stopPropagation(), x._jQueryInterface.call(o.default(this), "toggle")
})).on("click.bs.dropdown.data-api", ".dropdown form", (function (t) {
t.stopPropagation()
})), o.default.fn[k] = x._jQueryInterface, o.default.fn[k].Constructor = x, o.default.fn[k].noConflict = function () {
return o.default.fn[k] = A, x._jQueryInterface
};
var P = o.default.fn.modal,
R = {
backdrop: !0,
keyboard: !0,
focus: !0,
show: !0
},
L = {
backdrop: "(boolean|string)",
keyboard: "boolean",
focus: "boolean",
show: "boolean"
},
q = function () {
function t(t, e) {
this._config = this._getConfig(e), this._element = t, this._dialog = t.querySelector(".modal-dialog"), this._backdrop = null, this._isShown = !1, this._isBodyOverflowing = !1, this._ignoreBackdropClick = !1, this._isTransitioning = !1, this._scrollbarWidth = 0
}
var e = t.prototype;
return e.toggle = function (t) {
return this._isShown ? this.hide() : this.show(t)
}, e.show = function (t) {
var e = this;
if (!this._isShown && !this._isTransitioning) {
o.default(this._element).hasClass("fade") && (this._isTransitioning = !0);
var n = o.default.Event("show.bs.modal", {
relatedTarget: t
});
o.default(this._element).trigger(n), this._isShown || n.isDefaultPrevented() || (this._isShown = !0, this._checkScrollbar(), this._setScrollbar(), this._adjustDialog(), this._setEscapeEvent(), this._setResizeEvent(), o.default(this._element).on("click.dismiss.bs.modal", '[data-dismiss="modal"]', (function (t) {
return e.hide(t)
})), o.default(this._dialog).on("mousedown.dismiss.bs.modal", (function () {
o.default(e._element).one("mouseup.dismiss.bs.modal", (function (t) {
o.default(t.target).is(e._element) && (e._ignoreBackdropClick = !0)
}))
})), this._showBackdrop((function () {
return e._showElement(t)
})))
}
}, e.hide = function (t) {
var e = this;
if (t && t.preventDefault(), this._isShown && !this._isTransitioning) {
var n = o.default.Event("hide.bs.modal");
if (o.default(this._element).trigger(n), this._isShown && !n.isDefaultPrevented()) {
this._isShown = !1;
var i = o.default(this._element).hasClass("fade");
if (i && (this._isTransitioning = !0), this._setEscapeEvent(), this._setResizeEvent(), o.default(document).off("focusin.bs.modal"), o.default(this._element).removeClass("show"), o.default(this._element).off("click.dismiss.bs.modal"), o.default(this._dialog).off("mousedown.dismiss.bs.modal"), i) {
var a = d.getTransitionDurationFromElement(this._element);
o.default(this._element).one(d.TRANSITION_END, (function (t) {
return e._hideModal(t)
})).emulateTransitionEnd(a)
} else this._hideModal()
}
}
}, e.dispose = function () {
[window, this._element, this._dialog].forEach((function (t) {
return o.default(t).off(".bs.modal")
})), o.default(document).off("focusin.bs.modal"), o.default.removeData(this._element, "bs.modal"), this._config = null, this._element = null, this._dialog = null, this._backdrop = null, this._isShown = null, this._isBodyOverflowing = null, this._ignoreBackdropClick = null, this._isTransitioning = null, this._scrollbarWidth = null
}, e.handleUpdate = function () {
this._adjustDialog()
}, e._getConfig = function (t) {
return t = r({}, R, t), d.typeCheckConfig("modal", t, L), t
}, e._triggerBackdropTransition = function () {
var t = this;
if ("static" === this._config.backdrop) {
var e = o.default.Event("hidePrevented.bs.modal");
if (o.default(this._element).trigger(e), e.isDefaultPrevented()) return;
var n = this._element.scrollHeight > document.documentElement.clientHeight;
n || (this._element.style.overflowY = "hidden"), this._element.classList.add("modal-static");
var i = d.getTransitionDurationFromElement(this._dialog);
o.default(this._element).off(d.TRANSITION_END), o.default(this._element).one(d.TRANSITION_END, (function () {
t._element.classList.remove("modal-static"), n || o.default(t._element).one(d.TRANSITION_END, (function () {
t._element.style.overflowY = ""
})).emulateTransitionEnd(t._element, i)
})).emulateTransitionEnd(i), this._element.focus()
} else this.hide()
}, e._showElement = function (t) {
var e = this,
n = o.default(this._element).hasClass("fade"),
i = this._dialog ? this._dialog.querySelector(".modal-body") : null;
this._element.parentNode && this._element.parentNode.nodeType === Node.ELEMENT_NODE || document.body.appendChild(this._element), this._element.style.display = "block", this._element.removeAttribute("aria-hidden"), this._element.setAttribute("aria-modal", !0), this._element.setAttribute("role", "dialog"), o.default(this._dialog).hasClass("modal-dialog-scrollable") && i ? i.scrollTop = 0 : this._element.scrollTop = 0, n && d.reflow(this._element), o.default(this._element).addClass("show"), this._config.focus && this._enforceFocus();
var a = o.default.Event("shown.bs.modal", {
relatedTarget: t
}),
s = function () {
e._config.focus && e._element.focus(), e._isTransitioning = !1, o.default(e._element).trigger(a)
};
if (n) {
var l = d.getTransitionDurationFromElement(this._dialog);
o.default(this._dialog).one(d.TRANSITION_END, s).emulateTransitionEnd(l)
} else s()
}, e._enforceFocus = function () {
var t = this;
o.default(document).off("focusin.bs.modal").on("focusin.bs.modal", (function (e) {
document !== e.target && t._element !== e.target && 0 === o.default(t._element).has(e.target).length && t._element.focus()
}))
}, e._setEscapeEvent = function () {
var t = this;
this._isShown ? o.default(this._element).on("keydown.dismiss.bs.modal", (function (e) {
t._config.keyboard && 27 === e.which ? (e.preventDefault(), t.hide()) : t._config.keyboard || 27 !== e.which || t._triggerBackdropTransition()
})) : this._isShown || o.default(this._element).off("keydown.dismiss.bs.modal")
}, e._setResizeEvent = function () {
var t = this;
this._isShown ? o.default(window).on("resize.bs.modal", (function (e) {
return t.handleUpdate(e)
})) : o.default(window).off("resize.bs.modal")
}, e._hideModal = function () {
var t = this;
this._element.style.display = "none", this._element.setAttribute("aria-hidden", !0), this._element.removeAttribute("aria-modal"), this._element.removeAttribute("role"), this._isTransitioning = !1, this._showBackdrop((function () {
o.default(document.body).removeClass("modal-open"), t._resetAdjustments(), t._resetScrollbar(), o.default(t._element).trigger("hidden.bs.modal")
}))
}, e._removeBackdrop = function () {
this._backdrop && (o.default(this._backdrop).remove(), this._backdrop = null)
}, e._showBackdrop = function (t) {
var e = this,
n = o.default(this._element).hasClass("fade") ? "fade" : "";
if (this._isShown && this._config.backdrop) {
if (this._backdrop = document.createElement("div"), this._backdrop.className = "modal-backdrop", n && this._backdrop.classList.add(n), o.default(this._backdrop).appendTo(document.body), o.default(this._element).on("click.dismiss.bs.modal", (function (t) {
e._ignoreBackdropClick ? e._ignoreBackdropClick = !1 : t.target === t.currentTarget && e._triggerBackdropTransition()
})), n && d.reflow(this._backdrop), o.default(this._backdrop).addClass("show"), !t) return;
if (!n) return void t();
var i = d.getTransitionDurationFromElement(this._backdrop);
o.default(this._backdrop).one(d.TRANSITION_END, t).emulateTransitionEnd(i)
} else if (!this._isShown && this._backdrop) {
o.default(this._backdrop).removeClass("show");
var a = function () {
e._removeBackdrop(), t && t()
};
if (o.default(this._element).hasClass("fade")) {
var s = d.getTransitionDurationFromElement(this._backdrop);
o.default(this._backdrop).one(d.TRANSITION_END, a).emulateTransitionEnd(s)
} else a()
} else t && t()
}, e._adjustDialog = function () {
var t = this._element.scrollHeight > document.documentElement.clientHeight;
!this._isBodyOverflowing && t && (this._element.style.paddingLeft = this._scrollbarWidth + "px"), this._isBodyOverflowing && !t && (this._element.style.paddingRight = this._scrollbarWidth + "px")
}, e._resetAdjustments = function () {
this._element.style.paddingLeft = "", this._element.style.paddingRight = ""
}, e._checkScrollbar = function () {
var t = document.body.getBoundingClientRect();
this._isBodyOverflowing = Math.round(t.left + t.right) < window.innerWidth, this._scrollbarWidth = this._getScrollbarWidth()
}, e._setScrollbar = function () {
var t = this;
if (this._isBodyOverflowing) {
var e = [].slice.call(document.querySelectorAll(".fixed-top, .fixed-bottom, .is-fixed, .sticky-top")),
n = [].slice.call(document.querySelectorAll(".sticky-top"));
o.default(e).each((function (e, n) {
var i = n.style.paddingRight,
a = o.default(n).css("padding-right");
o.default(n).data("padding-right", i).css("padding-right", parseFloat(a) + t._scrollbarWidth + "px")
})), o.default(n).each((function (e, n) {
var i = n.style.marginRight,
a = o.default(n).css("margin-right");
o.default(n).data("margin-right", i).css("margin-right", parseFloat(a) - t._scrollbarWidth + "px")
}));
var i = document.body.style.paddingRight,
a = o.default(document.body).css("padding-right");
o.default(document.body).data("padding-right", i).css("padding-right", parseFloat(a) + this._scrollbarWidth + "px")
}
o.default(document.body).addClass("modal-open")
}, e._resetScrollbar = function () {
var t = [].slice.call(document.querySelectorAll(".fixed-top, .fixed-bottom, .is-fixed, .sticky-top"));
o.default(t).each((function (t, e) {
var n = o.default(e).data("padding-right");
o.default(e).removeData("padding-right"), e.style.paddingRight = n || ""
}));
var e = [].slice.call(document.querySelectorAll(".sticky-top"));
o.default(e).each((function (t, e) {
var n = o.default(e).data("margin-right");
"undefined" != typeof n && o.default(e).css("margin-right", n).removeData("margin-right")
}));
var n = o.default(document.body).data("padding-right");
o.default(document.body).removeData("padding-right"), document.body.style.paddingRight = n || ""
}, e._getScrollbarWidth = function () {
var t = document.createElement("div");
t.className = "modal-scrollbar-measure", document.body.appendChild(t);
var e = t.getBoundingClientRect().width - t.clientWidth;
return document.body.removeChild(t), e
}, t._jQueryInterface = function (e, n) {
return this.each((function () {
var i = o.default(this).data("bs.modal"),
a = r({}, R, o.default(this).data(), "object" == typeof e && e ? e : {});
if (i || (i = new t(this, a), o.default(this).data("bs.modal", i)), "string" == typeof e) {
if ("undefined" == typeof i[e]) throw new TypeError('No method named "' + e + '"');
i[e](n)
} else a.show && i.show(n)
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return R
}
}]), t
}();
o.default(document).on("click.bs.modal.data-api", '[data-toggle="modal"]', (function (t) {
var e, n = this,
i = d.getSelectorFromElement(this);
i && (e = document.querySelector(i));
var a = o.default(e).data("bs.modal") ? "toggle" : r({}, o.default(e).data(), o.default(this).data());
"A" !== this.tagName && "AREA" !== this.tagName || t.preventDefault();
var s = o.default(e).one("show.bs.modal", (function (t) {
t.isDefaultPrevented() || s.one("hidden.bs.modal", (function () {
o.default(n).is(":visible") && n.focus()
}))
}));
q._jQueryInterface.call(o.default(e), a, this)
})), o.default.fn.modal = q._jQueryInterface, o.default.fn.modal.Constructor = q, o.default.fn.modal.noConflict = function () {
return o.default.fn.modal = P, q._jQueryInterface
};
var F = ["background", "cite", "href", "itemtype", "longdesc", "poster", "src", "xlink:href"],
Q = {
"*": ["class", "dir", "id", "lang", "role", /^aria-[\w-]*$/i],
a: ["target", "href", "title", "rel"],
area: [],
b: [],
br: [],
col: [],
code: [],
div: [],
em: [],
hr: [],
h1: [],
h2: [],
h3: [],
h4: [],
h5: [],
h6: [],
i: [],
img: ["src", "srcset", "alt", "title", "width", "height"],
li: [],
ol: [],
p: [],
pre: [],
s: [],
small: [],
span: [],
sub: [],
sup: [],
strong: [],
u: [],
ul: []
},
B = /^(?:(?:https?|mailto|ftp|tel|file):|[^#&/:?]*(?:[#/?]|$))/gi,
H = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i;
function U(t, e, n) {
if (0 === t.length) return t;
if (n && "function" == typeof n) return n(t);
for (var i = (new window.DOMParser).parseFromString(t, "text/html"), o = Object.keys(e), a = [].slice.call(i.body.querySelectorAll("*")), s = function (t, n) {
var i = a[t],
s = i.nodeName.toLowerCase();
if (-1 === o.indexOf(i.nodeName.toLowerCase())) return i.parentNode.removeChild(i), "continue";
var l = [].slice.call(i.attributes),
r = [].concat(e["*"] || [], e[s] || []);
l.forEach((function (t) {
(function (t, e) {
var n = t.nodeName.toLowerCase();
if (-1 !== e.indexOf(n)) return -1 === F.indexOf(n) || Boolean(t.nodeValue.match(B) || t.nodeValue.match(H));
for (var i = e.filter((function (t) {
return t instanceof RegExp
})), o = 0, a = i.length; o < a; o++)
if (n.match(i[o])) return !0;
return !1
})(t, r) || i.removeAttribute(t.nodeName)
}))
}, l = 0, r = a.length; l < r; l++) s(l);
return i.body.innerHTML
}
var M = "tooltip",
W = o.default.fn[M],
V = new RegExp("(^|\\s)bs-tooltip\\S+", "g"),
z = ["sanitize", "whiteList", "sanitizeFn"],
K = {
animation: "boolean",
template: "string",
title: "(string|element|function)",
trigger: "string",
delay: "(number|object)",
html: "boolean",
selector: "(string|boolean)",
placement: "(string|function)",
offset: "(number|string|function)",
container: "(string|element|boolean)",
fallbackPlacement: "(string|array)",
boundary: "(string|element)",
sanitize: "boolean",
sanitizeFn: "(null|function)",
whiteList: "object",
popperConfig: "(null|object)"
},
X = {
AUTO: "auto",
TOP: "top",
RIGHT: "right",
BOTTOM: "bottom",
LEFT: "left"
},
Y = {
animation: !0,
template: '
',
trigger: "hover focus",
title: "",
delay: 0,
html: !1,
selector: !1,
placement: "top",
offset: 0,
container: !1,
fallbackPlacement: "flip",
boundary: "scrollParent",
sanitize: !0,
sanitizeFn: null,
whiteList: Q,
popperConfig: null
},
$ = {
HIDE: "hide.bs.tooltip",
HIDDEN: "hidden.bs.tooltip",
SHOW: "show.bs.tooltip",
SHOWN: "shown.bs.tooltip",
INSERTED: "inserted.bs.tooltip",
CLICK: "click.bs.tooltip",
FOCUSIN: "focusin.bs.tooltip",
FOCUSOUT: "focusout.bs.tooltip",
MOUSEENTER: "mouseenter.bs.tooltip",
MOUSELEAVE: "mouseleave.bs.tooltip"
},
J = function () {
function t(t, e) {
if ("undefined" == typeof a.default) throw new TypeError("Bootstrap's tooltips require Popper.js (https://popper.js.org/)");
this._isEnabled = !0, this._timeout = 0, this._hoverState = "", this._activeTrigger = {}, this._popper = null, this.element = t, this.config = this._getConfig(e), this.tip = null, this._setListeners()
}
var e = t.prototype;
return e.enable = function () {
this._isEnabled = !0
}, e.disable = function () {
this._isEnabled = !1
}, e.toggleEnabled = function () {
this._isEnabled = !this._isEnabled
}, e.toggle = function (t) {
if (this._isEnabled)
if (t) {
var e = this.constructor.DATA_KEY,
n = o.default(t.currentTarget).data(e);
n || (n = new this.constructor(t.currentTarget, this._getDelegateConfig()), o.default(t.currentTarget).data(e, n)), n._activeTrigger.click = !n._activeTrigger.click, n._isWithActiveTrigger() ? n._enter(null, n) : n._leave(null, n)
} else {
if (o.default(this.getTipElement()).hasClass("show")) return void this._leave(null, this);
this._enter(null, this)
}
}, e.dispose = function () {
clearTimeout(this._timeout), o.default.removeData(this.element, this.constructor.DATA_KEY), o.default(this.element).off(this.constructor.EVENT_KEY), o.default(this.element).closest(".modal").off("hide.bs.modal", this._hideModalHandler), this.tip && o.default(this.tip).remove(), this._isEnabled = null, this._timeout = null, this._hoverState = null, this._activeTrigger = null, this._popper && this._popper.destroy(), this._popper = null, this.element = null, this.config = null, this.tip = null
}, e.show = function () {
var t = this;
if ("none" === o.default(this.element).css("display")) throw new Error("Please use show on visible elements");
var e = o.default.Event(this.constructor.Event.SHOW);
if (this.isWithContent() && this._isEnabled) {
o.default(this.element).trigger(e);
var n = d.findShadowRoot(this.element),
i = o.default.contains(null !== n ? n : this.element.ownerDocument.documentElement, this.element);
if (e.isDefaultPrevented() || !i) return;
var s = this.getTipElement(),
l = d.getUID(this.constructor.NAME);
s.setAttribute("id", l), this.element.setAttribute("aria-describedby", l), this.setContent(), this.config.animation && o.default(s).addClass("fade");
var r = "function" == typeof this.config.placement ? this.config.placement.call(this, s, this.element) : this.config.placement,
u = this._getAttachment(r);
this.addAttachmentClass(u);
var f = this._getContainer();
o.default(s).data(this.constructor.DATA_KEY, this), o.default.contains(this.element.ownerDocument.documentElement, this.tip) || o.default(s).appendTo(f), o.default(this.element).trigger(this.constructor.Event.INSERTED), this._popper = new a.default(this.element, s, this._getPopperConfig(u)), o.default(s).addClass("show"), "ontouchstart" in document.documentElement && o.default(document.body).children().on("mouseover", null, o.default.noop);
var c = function () {
t.config.animation && t._fixTransition();
var e = t._hoverState;
t._hoverState = null, o.default(t.element).trigger(t.constructor.Event.SHOWN), "out" === e && t._leave(null, t)
};
if (o.default(this.tip).hasClass("fade")) {
var h = d.getTransitionDurationFromElement(this.tip);
o.default(this.tip).one(d.TRANSITION_END, c).emulateTransitionEnd(h)
} else c()
}
}, e.hide = function (t) {
var e = this,
n = this.getTipElement(),
i = o.default.Event(this.constructor.Event.HIDE),
a = function () {
"show" !== e._hoverState && n.parentNode && n.parentNode.removeChild(n), e._cleanTipClass(), e.element.removeAttribute("aria-describedby"), o.default(e.element).trigger(e.constructor.Event.HIDDEN), null !== e._popper && e._popper.destroy(), t && t()
};
if (o.default(this.element).trigger(i), !i.isDefaultPrevented()) {
if (o.default(n).removeClass("show"), "ontouchstart" in document.documentElement && o.default(document.body).children().off("mouseover", null, o.default.noop), this._activeTrigger.click = !1, this._activeTrigger.focus = !1, this._activeTrigger.hover = !1, o.default(this.tip).hasClass("fade")) {
var s = d.getTransitionDurationFromElement(n);
o.default(n).one(d.TRANSITION_END, a).emulateTransitionEnd(s)
} else a();
this._hoverState = ""
}
}, e.update = function () {
null !== this._popper && this._popper.scheduleUpdate()
}, e.isWithContent = function () {
return Boolean(this.getTitle())
}, e.addAttachmentClass = function (t) {
o.default(this.getTipElement()).addClass("bs-tooltip-" + t)
}, e.getTipElement = function () {
return this.tip = this.tip || o.default(this.config.template)[0], this.tip
}, e.setContent = function () {
var t = this.getTipElement();
this.setElementContent(o.default(t.querySelectorAll(".tooltip-inner")), this.getTitle()), o.default(t).removeClass("fade show")
}, e.setElementContent = function (t, e) {
"object" != typeof e || !e.nodeType && !e.jquery ? this.config.html ? (this.config.sanitize && (e = U(e, this.config.whiteList, this.config.sanitizeFn)), t.html(e)) : t.text(e) : this.config.html ? o.default(e).parent().is(t) || t.empty().append(e) : t.text(o.default(e).text())
}, e.getTitle = function () {
var t = this.element.getAttribute("data-original-title");
return t || (t = "function" == typeof this.config.title ? this.config.title.call(this.element) : this.config.title), t
}, e._getPopperConfig = function (t) {
var e = this;
return r({}, {
placement: t,
modifiers: {
offset: this._getOffset(),
flip: {
behavior: this.config.fallbackPlacement
},
arrow: {
element: ".arrow"
},
preventOverflow: {
boundariesElement: this.config.boundary
}
},
onCreate: function (t) {
t.originalPlacement !== t.placement && e._handlePopperPlacementChange(t)
},
onUpdate: function (t) {
return e._handlePopperPlacementChange(t)
}
}, this.config.popperConfig)
}, e._getOffset = function () {
var t = this,
e = {};
return "function" == typeof this.config.offset ? e.fn = function (e) {
return e.offsets = r({}, e.offsets, t.config.offset(e.offsets, t.element) || {}), e
} : e.offset = this.config.offset, e
}, e._getContainer = function () {
return !1 === this.config.container ? document.body : d.isElement(this.config.container) ? o.default(this.config.container) : o.default(document).find(this.config.container)
}, e._getAttachment = function (t) {
return X[t.toUpperCase()]
}, e._setListeners = function () {
var t = this;
this.config.trigger.split(" ").forEach((function (e) {
if ("click" === e) o.default(t.element).on(t.constructor.Event.CLICK, t.config.selector, (function (e) {
return t.toggle(e)
}));
else if ("manual" !== e) {
var n = "hover" === e ? t.constructor.Event.MOUSEENTER : t.constructor.Event.FOCUSIN,
i = "hover" === e ? t.constructor.Event.MOUSELEAVE : t.constructor.Event.FOCUSOUT;
o.default(t.element).on(n, t.config.selector, (function (e) {
return t._enter(e)
})).on(i, t.config.selector, (function (e) {
return t._leave(e)
}))
}
})), this._hideModalHandler = function () {
t.element && t.hide()
}, o.default(this.element).closest(".modal").on("hide.bs.modal", this._hideModalHandler), this.config.selector ? this.config = r({}, this.config, {
trigger: "manual",
selector: ""
}) : this._fixTitle()
}, e._fixTitle = function () {
var t = typeof this.element.getAttribute("data-original-title");
(this.element.getAttribute("title") || "string" !== t) && (this.element.setAttribute("data-original-title", this.element.getAttribute("title") || ""), this.element.setAttribute("title", ""))
}, e._enter = function (t, e) {
var n = this.constructor.DATA_KEY;
(e = e || o.default(t.currentTarget).data(n)) || (e = new this.constructor(t.currentTarget, this._getDelegateConfig()), o.default(t.currentTarget).data(n, e)), t && (e._activeTrigger["focusin" === t.type ? "focus" : "hover"] = !0), o.default(e.getTipElement()).hasClass("show") || "show" === e._hoverState ? e._hoverState = "show" : (clearTimeout(e._timeout), e._hoverState = "show", e.config.delay && e.config.delay.show ? e._timeout = setTimeout((function () {
"show" === e._hoverState && e.show()
}), e.config.delay.show) : e.show())
}, e._leave = function (t, e) {
var n = this.constructor.DATA_KEY;
(e = e || o.default(t.currentTarget).data(n)) || (e = new this.constructor(t.currentTarget, this._getDelegateConfig()), o.default(t.currentTarget).data(n, e)), t && (e._activeTrigger["focusout" === t.type ? "focus" : "hover"] = !1), e._isWithActiveTrigger() || (clearTimeout(e._timeout), e._hoverState = "out", e.config.delay && e.config.delay.hide ? e._timeout = setTimeout((function () {
"out" === e._hoverState && e.hide()
}), e.config.delay.hide) : e.hide())
}, e._isWithActiveTrigger = function () {
for (var t in this._activeTrigger)
if (this._activeTrigger[t]) return !0;
return !1
}, e._getConfig = function (t) {
var e = o.default(this.element).data();
return Object.keys(e).forEach((function (t) {
-1 !== z.indexOf(t) && delete e[t]
})), "number" == typeof (t = r({}, this.constructor.Default, e, "object" == typeof t && t ? t : {})).delay && (t.delay = {
show: t.delay,
hide: t.delay
}), "number" == typeof t.title && (t.title = t.title.toString()), "number" == typeof t.content && (t.content = t.content.toString()), d.typeCheckConfig(M, t, this.constructor.DefaultType), t.sanitize && (t.template = U(t.template, t.whiteList, t.sanitizeFn)), t
}, e._getDelegateConfig = function () {
var t = {};
if (this.config)
for (var e in this.config) this.constructor.Default[e] !== this.config[e] && (t[e] = this.config[e]);
return t
}, e._cleanTipClass = function () {
var t = o.default(this.getTipElement()),
e = t.attr("class").match(V);
null !== e && e.length && t.removeClass(e.join(""))
}, e._handlePopperPlacementChange = function (t) {
this.tip = t.instance.popper, this._cleanTipClass(), this.addAttachmentClass(this._getAttachment(t.placement))
}, e._fixTransition = function () {
var t = this.getTipElement(),
e = this.config.animation;
null === t.getAttribute("x-placement") && (o.default(t).removeClass("fade"), this.config.animation = !1, this.hide(), this.show(), this.config.animation = e)
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this),
i = n.data("bs.tooltip"),
a = "object" == typeof e && e;
if ((i || !/dispose|hide/.test(e)) && (i || (i = new t(this, a), n.data("bs.tooltip", i)), "string" == typeof e)) {
if ("undefined" == typeof i[e]) throw new TypeError('No method named "' + e + '"');
i[e]()
}
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return Y
}
}, {
key: "NAME",
get: function () {
return M
}
}, {
key: "DATA_KEY",
get: function () {
return "bs.tooltip"
}
}, {
key: "Event",
get: function () {
return $
}
}, {
key: "EVENT_KEY",
get: function () {
return ".bs.tooltip"
}
}, {
key: "DefaultType",
get: function () {
return K
}
}]), t
}();
o.default.fn[M] = J._jQueryInterface, o.default.fn[M].Constructor = J, o.default.fn[M].noConflict = function () {
return o.default.fn[M] = W, J._jQueryInterface
};
var G = "popover",
Z = o.default.fn[G],
tt = new RegExp("(^|\\s)bs-popover\\S+", "g"),
et = r({}, J.Default, {
placement: "right",
trigger: "click",
content: "",
template: '
'
}),
nt = r({}, J.DefaultType, {
content: "(string|element|function)"
}),
it = {
HIDE: "hide.bs.popover",
HIDDEN: "hidden.bs.popover",
SHOW: "show.bs.popover",
SHOWN: "shown.bs.popover",
INSERTED: "inserted.bs.popover",
CLICK: "click.bs.popover",
FOCUSIN: "focusin.bs.popover",
FOCUSOUT: "focusout.bs.popover",
MOUSEENTER: "mouseenter.bs.popover",
MOUSELEAVE: "mouseleave.bs.popover"
},
ot = function (t) {
var e, n;
function i() {
return t.apply(this, arguments) || this
}
n = t, (e = i).prototype = Object.create(n.prototype), e.prototype.constructor = e, e.__proto__ = n;
var a = i.prototype;
return a.isWithContent = function () {
return this.getTitle() || this._getContent()
}, a.addAttachmentClass = function (t) {
o.default(this.getTipElement()).addClass("bs-popover-" + t)
}, a.getTipElement = function () {
return this.tip = this.tip || o.default(this.config.template)[0], this.tip
}, a.setContent = function () {
var t = o.default(this.getTipElement());
this.setElementContent(t.find(".popover-header"), this.getTitle());
var e = this._getContent();
"function" == typeof e && (e = e.call(this.element)), this.setElementContent(t.find(".popover-body"), e), t.removeClass("fade show")
}, a._getContent = function () {
return this.element.getAttribute("data-content") || this.config.content
}, a._cleanTipClass = function () {
var t = o.default(this.getTipElement()),
e = t.attr("class").match(tt);
null !== e && e.length > 0 && t.removeClass(e.join(""))
}, i._jQueryInterface = function (t) {
return this.each((function () {
var e = o.default(this).data("bs.popover"),
n = "object" == typeof t ? t : null;
if ((e || !/dispose|hide/.test(t)) && (e || (e = new i(this, n), o.default(this).data("bs.popover", e)), "string" == typeof t)) {
if ("undefined" == typeof e[t]) throw new TypeError('No method named "' + t + '"');
e[t]()
}
}))
}, l(i, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return et
}
}, {
key: "NAME",
get: function () {
return G
}
}, {
key: "DATA_KEY",
get: function () {
return "bs.popover"
}
}, {
key: "Event",
get: function () {
return it
}
}, {
key: "EVENT_KEY",
get: function () {
return ".bs.popover"
}
}, {
key: "DefaultType",
get: function () {
return nt
}
}]), i
}(J);
o.default.fn[G] = ot._jQueryInterface, o.default.fn[G].Constructor = ot, o.default.fn[G].noConflict = function () {
return o.default.fn[G] = Z, ot._jQueryInterface
};
var at = "scrollspy",
st = o.default.fn[at],
lt = {
offset: 10,
method: "auto",
target: ""
},
rt = {
offset: "number",
method: "string",
target: "(string|element)"
},
ut = function () {
function t(t, e) {
var n = this;
this._element = t, this._scrollElement = "BODY" === t.tagName ? window : t, this._config = this._getConfig(e), this._selector = this._config.target + " .nav-link," + this._config.target + " .list-group-item," + this._config.target + " .dropdown-item", this._offsets = [], this._targets = [], this._activeTarget = null, this._scrollHeight = 0, o.default(this._scrollElement).on("scroll.bs.scrollspy", (function (t) {
return n._process(t)
})), this.refresh(), this._process()
}
var e = t.prototype;
return e.refresh = function () {
var t = this,
e = this._scrollElement === this._scrollElement.window ? "offset" : "position",
n = "auto" === this._config.method ? e : this._config.method,
i = "position" === n ? this._getScrollTop() : 0;
this._offsets = [], this._targets = [], this._scrollHeight = this._getScrollHeight(), [].slice.call(document.querySelectorAll(this._selector)).map((function (t) {
var e, a = d.getSelectorFromElement(t);
if (a && (e = document.querySelector(a)), e) {
var s = e.getBoundingClientRect();
if (s.width || s.height) return [o.default(e)[n]().top + i, a]
}
return null
})).filter((function (t) {
return t
})).sort((function (t, e) {
return t[0] - e[0]
})).forEach((function (e) {
t._offsets.push(e[0]), t._targets.push(e[1])
}))
}, e.dispose = function () {
o.default.removeData(this._element, "bs.scrollspy"), o.default(this._scrollElement).off(".bs.scrollspy"), this._element = null, this._scrollElement = null, this._config = null, this._selector = null, this._offsets = null, this._targets = null, this._activeTarget = null, this._scrollHeight = null
}, e._getConfig = function (t) {
if ("string" != typeof (t = r({}, lt, "object" == typeof t && t ? t : {})).target && d.isElement(t.target)) {
var e = o.default(t.target).attr("id");
e || (e = d.getUID(at), o.default(t.target).attr("id", e)), t.target = "#" + e
}
return d.typeCheckConfig(at, t, rt), t
}, e._getScrollTop = function () {
return this._scrollElement === window ? this._scrollElement.pageYOffset : this._scrollElement.scrollTop
}, e._getScrollHeight = function () {
return this._scrollElement.scrollHeight || Math.max(document.body.scrollHeight, document.documentElement.scrollHeight)
}, e._getOffsetHeight = function () {
return this._scrollElement === window ? window.innerHeight : this._scrollElement.getBoundingClientRect().height
}, e._process = function () {
var t = this._getScrollTop() + this._config.offset,
e = this._getScrollHeight(),
n = this._config.offset + e - this._getOffsetHeight();
if (this._scrollHeight !== e && this.refresh(), t >= n) {
var i = this._targets[this._targets.length - 1];
this._activeTarget !== i && this._activate(i)
} else {
if (this._activeTarget && t < this._offsets[0] && this._offsets[0] > 0) return this._activeTarget = null, void this._clear();
for (var o = this._offsets.length; o--;) {
this._activeTarget !== this._targets[o] && t >= this._offsets[o] && ("undefined" == typeof this._offsets[o + 1] || t < this._offsets[o + 1]) && this._activate(this._targets[o])
}
}
}, e._activate = function (t) {
this._activeTarget = t, this._clear();
var e = this._selector.split(",").map((function (e) {
return e + '[data-target="' + t + '"],' + e + '[href="' + t + '"]'
})),
n = o.default([].slice.call(document.querySelectorAll(e.join(","))));
n.hasClass("dropdown-item") ? (n.closest(".dropdown").find(".dropdown-toggle").addClass("active"), n.addClass("active")) : (n.addClass("active"), n.parents(".nav, .list-group").prev(".nav-link, .list-group-item").addClass("active"), n.parents(".nav, .list-group").prev(".nav-item").children(".nav-link").addClass("active")), o.default(this._scrollElement).trigger("activate.bs.scrollspy", {
relatedTarget: t
})
}, e._clear = function () {
[].slice.call(document.querySelectorAll(this._selector)).filter((function (t) {
return t.classList.contains("active")
})).forEach((function (t) {
return t.classList.remove("active")
}))
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this).data("bs.scrollspy");
if (n || (n = new t(this, "object" == typeof e && e), o.default(this).data("bs.scrollspy", n)), "string" == typeof e) {
if ("undefined" == typeof n[e]) throw new TypeError('No method named "' + e + '"');
n[e]()
}
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "Default",
get: function () {
return lt
}
}]), t
}();
o.default(window).on("load.bs.scrollspy.data-api", (function () {
for (var t = [].slice.call(document.querySelectorAll('[data-spy="scroll"]')), e = t.length; e--;) {
var n = o.default(t[e]);
ut._jQueryInterface.call(n, n.data())
}
})), o.default.fn[at] = ut._jQueryInterface, o.default.fn[at].Constructor = ut, o.default.fn[at].noConflict = function () {
return o.default.fn[at] = st, ut._jQueryInterface
};
var dt = o.default.fn.tab,
ft = function () {
function t(t) {
this._element = t
}
var e = t.prototype;
return e.show = function () {
var t = this;
if (!(this._element.parentNode && this._element.parentNode.nodeType === Node.ELEMENT_NODE && o.default(this._element).hasClass("active") || o.default(this._element).hasClass("disabled"))) {
var e, n, i = o.default(this._element).closest(".nav, .list-group")[0],
a = d.getSelectorFromElement(this._element);
if (i) {
var s = "UL" === i.nodeName || "OL" === i.nodeName ? "> li > .active" : ".active";
n = (n = o.default.makeArray(o.default(i).find(s)))[n.length - 1]
}
var l = o.default.Event("hide.bs.tab", {
relatedTarget: this._element
}),
r = o.default.Event("show.bs.tab", {
relatedTarget: n
});
if (n && o.default(n).trigger(l), o.default(this._element).trigger(r), !r.isDefaultPrevented() && !l.isDefaultPrevented()) {
a && (e = document.querySelector(a)), this._activate(this._element, i);
var u = function () {
var e = o.default.Event("hidden.bs.tab", {
relatedTarget: t._element
}),
i = o.default.Event("shown.bs.tab", {
relatedTarget: n
});
o.default(n).trigger(e), o.default(t._element).trigger(i)
};
e ? this._activate(e, e.parentNode, u) : u()
}
}
}, e.dispose = function () {
o.default.removeData(this._element, "bs.tab"), this._element = null
}, e._activate = function (t, e, n) {
var i = this,
a = (!e || "UL" !== e.nodeName && "OL" !== e.nodeName ? o.default(e).children(".active") : o.default(e).find("> li > .active"))[0],
s = n && a && o.default(a).hasClass("fade"),
l = function () {
return i._transitionComplete(t, a, n)
};
if (a && s) {
var r = d.getTransitionDurationFromElement(a);
o.default(a).removeClass("show").one(d.TRANSITION_END, l).emulateTransitionEnd(r)
} else l()
}, e._transitionComplete = function (t, e, n) {
if (e) {
o.default(e).removeClass("active");
var i = o.default(e.parentNode).find("> .dropdown-menu .active")[0];
i && o.default(i).removeClass("active"), "tab" === e.getAttribute("role") && e.setAttribute("aria-selected", !1)
}
if (o.default(t).addClass("active"), "tab" === t.getAttribute("role") && t.setAttribute("aria-selected", !0), d.reflow(t), t.classList.contains("fade") && t.classList.add("show"), t.parentNode && o.default(t.parentNode).hasClass("dropdown-menu")) {
var a = o.default(t).closest(".dropdown")[0];
if (a) {
var s = [].slice.call(a.querySelectorAll(".dropdown-toggle"));
o.default(s).addClass("active")
}
t.setAttribute("aria-expanded", !0)
}
n && n()
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this),
i = n.data("bs.tab");
if (i || (i = new t(this), n.data("bs.tab", i)), "string" == typeof e) {
if ("undefined" == typeof i[e]) throw new TypeError('No method named "' + e + '"');
i[e]()
}
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}]), t
}();
o.default(document).on("click.bs.tab.data-api", '[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]', (function (t) {
t.preventDefault(), ft._jQueryInterface.call(o.default(this), "show")
})), o.default.fn.tab = ft._jQueryInterface, o.default.fn.tab.Constructor = ft, o.default.fn.tab.noConflict = function () {
return o.default.fn.tab = dt, ft._jQueryInterface
};
var ct = o.default.fn.toast,
ht = {
animation: "boolean",
autohide: "boolean",
delay: "number"
},
gt = {
animation: !0,
autohide: !0,
delay: 500
},
mt = function () {
function t(t, e) {
this._element = t, this._config = this._getConfig(e), this._timeout = null, this._setListeners()
}
var e = t.prototype;
return e.show = function () {
var t = this,
e = o.default.Event("show.bs.toast");
if (o.default(this._element).trigger(e), !e.isDefaultPrevented()) {
this._clearTimeout(), this._config.animation && this._element.classList.add("fade");
var n = function () {
t._element.classList.remove("showing"), t._element.classList.add("show"), o.default(t._element).trigger("shown.bs.toast"), t._config.autohide && (t._timeout = setTimeout((function () {
t.hide()
}), t._config.delay))
};
if (this._element.classList.remove("hide"), d.reflow(this._element), this._element.classList.add("showing"), this._config.animation) {
var i = d.getTransitionDurationFromElement(this._element);
o.default(this._element).one(d.TRANSITION_END, n).emulateTransitionEnd(i)
} else n()
}
}, e.hide = function () {
if (this._element.classList.contains("show")) {
var t = o.default.Event("hide.bs.toast");
o.default(this._element).trigger(t), t.isDefaultPrevented() || this._close()
}
}, e.dispose = function () {
this._clearTimeout(), this._element.classList.contains("show") && this._element.classList.remove("show"), o.default(this._element).off("click.dismiss.bs.toast"), o.default.removeData(this._element, "bs.toast"), this._element = null, this._config = null
}, e._getConfig = function (t) {
return t = r({}, gt, o.default(this._element).data(), "object" == typeof t && t ? t : {}), d.typeCheckConfig("toast", t, this.constructor.DefaultType), t
}, e._setListeners = function () {
var t = this;
o.default(this._element).on("click.dismiss.bs.toast", '[data-dismiss="toast"]', (function () {
return t.hide()
}))
}, e._close = function () {
var t = this,
e = function () {
t._element.classList.add("hide"), o.default(t._element).trigger("hidden.bs.toast")
};
if (this._element.classList.remove("show"), this._config.animation) {
var n = d.getTransitionDurationFromElement(this._element);
o.default(this._element).one(d.TRANSITION_END, e).emulateTransitionEnd(n)
} else e()
}, e._clearTimeout = function () {
clearTimeout(this._timeout), this._timeout = null
}, t._jQueryInterface = function (e) {
return this.each((function () {
var n = o.default(this),
i = n.data("bs.toast");
if (i || (i = new t(this, "object" == typeof e && e), n.data("bs.toast", i)), "string" == typeof e) {
if ("undefined" == typeof i[e]) throw new TypeError('No method named "' + e + '"');
i[e](this)
}
}))
}, l(t, null, [{
key: "VERSION",
get: function () {
return "4.5.3"
}
}, {
key: "DefaultType",
get: function () {
return ht
}
}, {
key: "Default",
get: function () {
return gt
}
}]), t
}();
o.default.fn.toast = mt._jQueryInterface, o.default.fn.toast.Constructor = mt, o.default.fn.toast.noConflict = function () {
return o.default.fn.toast = ct, mt._jQueryInterface
}, t.Alert = h, t.Button = m, t.Carousel = w, t.Collapse = D, t.Dropdown = x, t.Modal = q, t.Popover = ot, t.Scrollspy = ut, t.Tab = ft, t.Toast = mt, t.Tooltip = J, t.Util = d, Object.defineProperty(t, "__esModule", {
value: !0
})
}));
//# sourceMappingURL=bootstrap.min.js.map
;(function (root, factory) {
if (typeof define === 'function' && define.amd) {
define(['jquery'], factory);
} else if (typeof exports === 'object') {
module.exports = factory(require('jquery'));
} else {
root.jquery_mmenu_all_min_js = factory(root.jQuery);
}
}(this, function (jQuery) {
/*
* jQuery mmenu v6.0.2
* @requires jQuery 1.7.0 or later
*
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
* www.frebsite.nl
*
* License: CC-BY-NC-4.0
* http://creativecommons.org/licenses/by-nc/4.0/
*/
!function (e) {
function t() {
e[n].glbl || (r = {
$wndw: e(window),
$docu: e(document),
$html: e("html"),
$body: e("body")
}, s = {}, a = {}, o = {}, e.each([s, a, o], function (e, t) {
t.add = function (e) {
e = e.split(" ");
for (var n = 0, i = e.length; n < i; n++) t[e[n]] = t.mm(e[n])
}
}), s.mm = function (e) {
return "mm-" + e
}, s.add("wrapper menu panels panel nopanel highest opened subopened navbar hasnavbar title btn prev next listview nolistview inset vertical selected divider spacer hidden fullsubopen noanimation"), s.umm = function (e) {
return "mm-" == e.slice(0, 3) && (e = e.slice(3)), e
}, a.mm = function (e) {
return "mm-" + e
}, a.add("parent child"), o.mm = function (e) {
return e + ".mm"
}, o.add("transitionend webkitTransitionEnd click scroll resize keydown mousedown mouseup touchstart touchmove touchend orientationchange"), e[n]._c = s, e[n]._d = a, e[n]._e = o, e[n].glbl = r)
}
var n = "mmenu", i = "6.0.2";
if (!(e[n] && e[n].version > i)) {
e[n] = function (e, t, n) {
return this.$menu = e, this._api = ["bind", "getInstance", "initPanels", "openPanel", "closePanel", "closeAllPanels", "setSelected"], this.opts = t, this.conf = n, this.vars = {}, this.cbck = {}, this.mtch = {}, "function" == typeof this.___deprecated && this.___deprecated(), this._initAddons(), this._initExtensions(), this._initMenu(), this._initPanels(), this._initOpened(), this._initAnchors(), this._initMatchMedia(), "function" == typeof this.___debug && this.___debug(), this
}, e[n].version = i, e[n].addons = {}, e[n].uniqueId = 0, e[n].defaults = {
extensions: [],
initMenu: function () {
},
initPanels: function () {
},
navbar: {add: !0, title: "Menu", titleLink: "parent"},
onClick: {setSelected: !0},
slidingSubmenus: !0
}, e[n].configuration = {
classNames: {
divider: "Divider",
inset: "Inset",
nolistview: "NoListview",
nopanel: "NoPanel",
panel: "Panel",
selected: "Selected",
spacer: "Spacer",
vertical: "Vertical"
}, clone: !1, openingInterval: 25, panelNodetype: "ul, ol, div", transitionDuration: 400
}, e[n].prototype = {
getInstance: function () {
return this
}, initPanels: function (e) {
this._initPanels(e)
}, openPanel: function (t, i) {
if (this.trigger("openPanel:before", t), t && t.length && (t.is("." + s.panel) || (t = t.closest("." + s.panel)), t.is("." + s.panel))) {
var o = this;
if ("boolean" != typeof i && (i = !0), t.hasClass(s.vertical)) t.add(t.parents("." + s.vertical)).removeClass(s.hidden).parent("li").addClass(s.opened), this.openPanel(t.parents("." + s.panel).not("." + s.vertical).first()), this.trigger("openPanel:start", t), this.trigger("openPanel:finish", t); else {
if (t.hasClass(s.opened)) return;
var r = this.$pnls.children("." + s.panel), l = r.filter("." + s.opened);
if (!e[n].support.csstransitions) return l.addClass(s.hidden).removeClass(s.opened), t.removeClass(s.hidden).addClass(s.opened), this.trigger("openPanel:start", t), void this.trigger("openPanel:finish", t);
r.not(t).removeClass(s.subopened);
for (var d = t.data(a.parent); d;) d = d.closest("." + s.panel), d.is("." + s.vertical) || d.addClass(s.subopened), d = d.data(a.parent);
r.removeClass(s.highest).not(l).not(t).addClass(s.hidden), t.removeClass(s.hidden);
var c = function () {
l.removeClass(s.opened), t.addClass(s.opened), t.hasClass(s.subopened) ? (l.addClass(s.highest), t.removeClass(s.subopened)) : (l.addClass(s.subopened), t.addClass(s.highest)), this.trigger("openPanel:start", t)
}, h = function () {
l.removeClass(s.highest).addClass(s.hidden), t.removeClass(s.highest), this.trigger("openPanel:finish", t)
};
i && !t.hasClass(s.noanimation) ? setTimeout(function () {
o.__transitionend(t, function () {
h.call(o)
}, o.conf.transitionDuration), c.call(o)
}, this.conf.openingInterval) : (c.call(this), h.call(this))
}
this.trigger("openPanel:after", t)
}
}, closePanel: function (e) {
this.trigger("closePanel:before", e);
var t = e.parent();
t.hasClass(s.vertical) && (t.removeClass(s.opened), this.trigger("closePanel", e)), this.trigger("closePanel:after", e)
}, closeAllPanels: function () {
this.trigger("closeAllPanels:before"), this.$pnls.find("." + s.listview).children().removeClass(s.selected).filter("." + s.vertical).removeClass(s.opened);
var e = this.$pnls.children("." + s.panel), t = e.first();
this.$pnls.children("." + s.panel).not(t).removeClass(s.subopened).removeClass(s.opened).removeClass(s.highest).addClass(s.hidden), this.openPanel(t), this.trigger("closeAllPanels:after")
}, togglePanel: function (e) {
var t = e.parent();
t.hasClass(s.vertical) && this[t.hasClass(s.opened) ? "closePanel" : "openPanel"](e)
}, setSelected: function (e) {
this.trigger("setSelected:before", e), this.$menu.find("." + s.listview).children("." + s.selected).removeClass(s.selected), e.addClass(s.selected), this.trigger("setSelected:after", e)
}, bind: function (e, t) {
this.cbck[e] = this.cbck[e] || [], this.cbck[e].push(t)
}, trigger: function () {
var e = this, t = Array.prototype.slice.call(arguments), n = t.shift();
if (this.cbck[n]) for (var i = 0, s = this.cbck[n].length; i < s; i++) this.cbck[n][i].apply(e, t)
}, matchMedia: function (e, t, n) {
var i = {yes: t, no: n};
this.mtch[e] = this.mtch[e] || [], this.mtch[e].push(i)
}, _initAddons: function () {
this.trigger("initAddons:before");
var t;
for (t in e[n].addons) e[n].addons[t].add.call(this), e[n].addons[t].add = function () {
};
for (t in e[n].addons) e[n].addons[t].setup.call(this);
this.trigger("initAddons:after")
}, _initExtensions: function () {
this.trigger("initExtensions:before");
var e = this;
this.opts.extensions.constructor === Array && (this.opts.extensions = {all: this.opts.extensions});
for (var t in this.opts.extensions) this.opts.extensions[t] = this.opts.extensions[t].length ? "mm-" + this.opts.extensions[t].join(" mm-") : "", this.opts.extensions[t] && !function (t) {
e.matchMedia(t, function () {
this.$menu.addClass(this.opts.extensions[t])
}, function () {
this.$menu.removeClass(this.opts.extensions[t])
})
}(t);
this.trigger("initExtensions:after")
}, _initMenu: function () {
this.trigger("initMenu:before");
this.conf.clone && (this.$orig = this.$menu, this.$menu = this.$orig.clone(), this.$menu.add(this.$menu.find("[id]")).filter("[id]").each(function () {
e(this).attr("id", s.mm(e(this).attr("id")))
})), this.opts.initMenu.call(this, this.$menu, this.$orig), this.$menu.attr("id", this.$menu.attr("id") || this.__getUniqueId()), this.$pnls = e('').append(this.$menu.children(this.conf.panelNodetype)).prependTo(this.$menu);
var t = [s.menu];
this.opts.slidingSubmenus || t.push(s.vertical), this.$menu.addClass(t.join(" ")).parent().addClass(s.wrapper), this.trigger("initMenu:after")
}, _initPanels: function (t) {
this.trigger("initPanels:before", t), t = t || this.$pnls.children(this.conf.panelNodetype);
var n = e(), i = this, a = function (t) {
t.filter(this.conf.panelNodetype).each(function () {
if ($panel = i._initPanel(e(this)), $panel) {
i._initNavbar($panel), i._initListview($panel), n = n.add($panel);
var t = $panel.children("." + s.listview).children("li").children(i.conf.panelNodeType).add($panel.children("." + i.conf.classNames.panel));
t.length && a.call(i, t)
}
})
};
a.call(this, t), this.opts.initPanels.call(this, n), this.trigger("initPanels:after", n)
}, _initPanel: function (e) {
this.trigger("initPanel:before", e);
if (this.__refactorClass(e, this.conf.classNames.panel, "panel"), this.__refactorClass(e, this.conf.classNames.nopanel, "nopanel"), this.__refactorClass(e, this.conf.classNames.vertical, "vertical"), this.__refactorClass(e, this.conf.classNames.inset, "inset"), e.filter("." + s.inset).addClass(s.nopanel), e.hasClass(s.nopanel)) return !1;
if (e.hasClass(s.panel)) return e;
var t = e.hasClass(s.vertical) || !this.opts.slidingSubmenus;
e.removeClass(s.vertical);
var n = e.attr("id") || this.__getUniqueId();
e.removeAttr("id"), e.is("ul, ol") && (e.wrap(""), e = e.parent()), e.addClass(s.panel + " " + s.hidden).attr("id", n);
var i = e.parent("li");
return t ? e.add(i).addClass(s.vertical) : e.appendTo(this.$pnls), i.length && (i.data(a.child, e), e.data(a.parent, i)), this.trigger("initPanel:after", e), e
}, _initNavbar: function (t) {
if (this.trigger("initNavbar:before", t), !t.children("." + s.navbar).length) {
var i = t.data(a.parent), o = e(''),
r = e[n].i18n(this.opts.navbar.title), l = !1;
if (i && i.length) {
if (i.hasClass(s.vertical)) return;
if (i.parent().is("." + s.listview)) var d = i.children("a, span").not("." + s.next); else var d = i.closest("." + s.panel).find('a[href="#' + t.attr("id") + '"]');
d = d.first(), i = d.closest("." + s.panel);
var c = i.attr("id");
switch (r = d.text(), this.opts.navbar.titleLink) {
case"anchor":
l = d.attr("href");
break;
case"parent":
l = "#" + c
}
o.append('')
} else if (!this.opts.navbar.title) return;
this.opts.navbar.add && t.addClass(s.hasnavbar), o.append('" + r + "").prependTo(t), this.trigger("initNavbar:after", t)
}
}, _initListview: function (t) {
this.trigger("initListview:before", t);
var n = this.__childAddBack(t, "ul, ol");
this.__refactorClass(n, this.conf.classNames.nolistview, "nolistview"), n.filter("." + this.conf.classNames.inset).addClass(s.nolistview);
var i = n.not("." + s.nolistview).addClass(s.listview).children();
this.__refactorClass(i, this.conf.classNames.selected, "selected"), this.__refactorClass(i, this.conf.classNames.divider, "divider"), this.__refactorClass(i, this.conf.classNames.spacer, "spacer");
var o = t.data(a.parent);
if (o && o.parent().is("." + s.listview) && !o.children("." + s.next).length) {
var r = o.children("a, span").first(),
l = e('').insertBefore(r);
r.is("span") && l.addClass(s.fullsubopen)
}
this.trigger("initListview:after", t)
}, _initOpened: function () {
this.trigger("initOpened:before");
var e = this.$pnls.find("." + s.listview).children("." + s.selected).removeClass(s.selected).last().addClass(s.selected),
t = e.length ? e.closest("." + s.panel) : this.$pnls.children("." + s.panel).first();
this.openPanel(t, !1), this.trigger("initOpened:after")
}, _initAnchors: function () {
var t = this;
r.$body.on(o.click + "-oncanvas", "a[href]", function (i) {
var a = e(this), o = !1, r = t.$menu.find(a).length;
for (var l in e[n].addons) if (e[n].addons[l].clickAnchor.call(t, a, r)) {
o = !0;
break
}
var d = a.attr("href");
if (!o && r && d.length > 1 && "#" == d.slice(0, 1)) try {
var c = e(d, t.$menu);
c.is("." + s.panel) && (o = !0, t[a.parent().hasClass(s.vertical) ? "togglePanel" : "openPanel"](c))
} catch (h) {
}
if (o && i.preventDefault(), !o && r && a.is("." + s.listview + " > li > a") && !a.is('[rel="external"]') && !a.is('[target="_blank"]')) {
t.__valueOrFn(t.opts.onClick.setSelected, a) && t.setSelected(e(i.target).parent());
var f = t.__valueOrFn(t.opts.onClick.preventDefault, a, "#" == d.slice(0, 1));
f && i.preventDefault(), t.__valueOrFn(t.opts.onClick.close, a, f) && t.close()
}
})
}, _initMatchMedia: function () {
var e = this;
this._fireMatchMedia(), r.$wndw.on(o.resize, function (t) {
e._fireMatchMedia()
})
}, _fireMatchMedia: function () {
for (var e in this.mtch) for (var t = window.matchMedia && window.matchMedia(e).matches ? "yes" : "no", n = 0; n < this.mtch[e].length; n++) this.mtch[e][n][t].call(this)
}, _getOriginalMenuId: function () {
var e = this.$menu.attr("id");
return this.conf.clone && e && e.length && (e = s.umm(e)), e
}, __api: function () {
var t = this, n = {};
return e.each(this._api, function (e) {
var i = this;
n[i] = function () {
var e = t[i].apply(t, arguments);
return "undefined" == typeof e ? n : e
}
}), n
}, __valueOrFn: function (e, t, n) {
return "function" == typeof e ? e.call(t[0]) : "undefined" == typeof e && "undefined" != typeof n ? n : e
}, __refactorClass: function (e, t, n) {
return e.filter("." + t).removeClass(t).addClass(s[n])
}, __findAddBack: function (e, t) {
return e.find(t).add(e.filter(t))
}, __childAddBack: function (e, t) {
return e.children(t).add(e.filter(t))
}, __filterListItems: function (e) {
return e.not("." + s.divider).not("." + s.hidden)
}, __filterListItemAnchors: function (e) {
return this.__filterListItems(e).children("a").not("." + s.next)
}, __transitionend: function (e, t, n) {
var i = !1, s = function (n) {
"undefined" != typeof n && n.target != e[0] || (i || (e.unbind(o.transitionend), e.unbind(o.webkitTransitionEnd), t.call(e[0])), i = !0)
};
e.on(o.transitionend, s), e.on(o.webkitTransitionEnd, s), setTimeout(s, 1.1 * n)
}, __getUniqueId: function () {
return s.mm(e[n].uniqueId++)
}
}, e.fn[n] = function (i, s) {
t(), i = e.extend(!0, {}, e[n].defaults, i), s = e.extend(!0, {}, e[n].configuration, s);
var a = e();
return this.each(function () {
var t = e(this);
if (!t.data(n)) {
var o = new e[n](t, i, s);
o.$menu.data(n, o.__api()), a = a.add(o.$menu)
}
}), a
}, e[n].i18n = function () {
var t = {};
return function (n) {
switch (typeof n) {
case"object":
return e.extend(t, n), t;
case"string":
return t[n] || n;
case"undefined":
default:
return t
}
}
}(), e[n].support = {
touch: "ontouchstart" in window || navigator.msMaxTouchPoints || !1,
csstransitions: function () {
return "undefined" == typeof Modernizr || "undefined" == typeof Modernizr.csstransitions || Modernizr.csstransitions
}(),
csstransforms: function () {
return "undefined" == typeof Modernizr || "undefined" == typeof Modernizr.csstransforms || Modernizr.csstransforms
}(),
csstransforms3d: function () {
return "undefined" == typeof Modernizr || "undefined" == typeof Modernizr.csstransforms3d || Modernizr.csstransforms3d
}()
};
var s, a, o, r
}
}(jQuery),/*
* jQuery mmenu offCanvas add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "offCanvas";
e[t].addons[n] = {
setup: function () {
if (this.opts[n]) {
var s = this, a = this.opts[n], r = this.conf[n];
o = e[t].glbl, this._api = e.merge(this._api, ["open", "close", "setPage"]), "object" != typeof a && (a = {}), "top" != a.position && "bottom" != a.position || (a.zposition = "front"), a = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], a), "string" != typeof r.pageSelector && (r.pageSelector = "> " + r.pageNodetype), o.$allMenus = (o.$allMenus || e()).add(this.$menu), this.vars.opened = !1;
var l = [i.offcanvas];
"left" != a.position && l.push(i.mm(a.position)), "back" != a.zposition && l.push(i.mm(a.zposition)), e[t].support.csstransforms || l.push(i["no-csstransforms"]), e[t].support.csstransforms3d || l.push(i["no-csstransforms3d"]), this.bind("initMenu:after", function () {
this.setPage(o.$page), this._initBlocker(), this["_initWindow_" + n](), this.$menu.addClass(l.join(" ")).parent("." + i.wrapper).removeClass(i.wrapper), this.$menu[r.menuInsertMethod](r.menuInsertSelector);
var e = window.location.hash;
if (e) {
var t = this._getOriginalMenuId();
t && t == e.slice(1) && this.open()
}
}), this.bind("initExtensions:after", function () {
for (var e = [i.mm("widescreen"), i.mm("iconbar")], t = 0; t < e.length; t++) for (var n in this.opts.extensions) if (this.opts.extensions[n].indexOf(e[t]) > -1) {
!function (t, n) {
s.matchMedia(t, function () {
o.$html.addClass(e[n])
}, function () {
o.$html.removeClass(e[n])
})
}(n, t);
break
}
}), this.bind("open:start:sr-aria", function () {
this.__sr_aria(this.$menu, "hidden", !1)
}), this.bind("close:finish:sr-aria", function () {
this.__sr_aria(this.$menu, "hidden", !0)
}), this.bind("initMenu:after:sr-aria", function () {
this.__sr_aria(this.$menu, "hidden", !0)
})
}
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("offcanvas slideout blocking modal background opening blocker page no-csstransforms3d"), s.add("style")
}, clickAnchor: function (e, t) {
var s = this;
if (this.opts[n]) {
var a = this._getOriginalMenuId();
if (a && e.is('[href="#' + a + '"]')) {
if (t) return !0;
var r = e.closest("." + i.menu);
if (r.length) {
var l = r.data("mmenu");
if (l && l.close) return l.close(), s.__transitionend(r, function () {
s.open()
}, s.conf.transitionDuration), !0
}
return this.open(), !0
}
if (o.$page) return a = o.$page.first().attr("id"), a && e.is('[href="#' + a + '"]') ? (this.close(), !0) : void 0
}
}
}, e[t].defaults[n] = {
position: "left",
zposition: "back",
blockUI: !0,
moveBackground: !0
}, e[t].configuration[n] = {
pageNodetype: "div",
pageSelector: null,
noPageSelector: [],
wrapPageIfNeeded: !0,
menuInsertMethod: "prependTo",
menuInsertSelector: "body"
}, e[t].prototype.open = function () {
if (this.trigger("open:before"), !this.vars.opened) {
var e = this;
this._openSetup(), setTimeout(function () {
e._openFinish()
}, this.conf.openingInterval), this.trigger("open:after")
}
}, e[t].prototype._openSetup = function () {
var t = this, r = this.opts[n];
this.closeAllOthers(), o.$page.each(function () {
e(this).data(s.style, e(this).attr("style") || "")
}), o.$wndw.trigger(a.resize + "-" + n, [!0]);
var l = [i.opened];
r.blockUI && l.push(i.blocking), "modal" == r.blockUI && l.push(i.modal), r.moveBackground && l.push(i.background), "left" != r.position && l.push(i.mm(this.opts[n].position)), "back" != r.zposition && l.push(i.mm(this.opts[n].zposition)), o.$html.addClass(l.join(" ")), setTimeout(function () {
t.vars.opened = !0
}, this.conf.openingInterval), this.$menu.addClass(i.opened)
}, e[t].prototype._openFinish = function () {
var e = this;
this.__transitionend(o.$page.first(), function () {
e.trigger("open:finish")
}, this.conf.transitionDuration), this.trigger("open:start"), o.$html.addClass(i.opening)
}, e[t].prototype.close = function () {
if (this.trigger("close:before"), this.vars.opened) {
var t = this;
this.__transitionend(o.$page.first(), function () {
t.$menu.removeClass(i.opened);
var a = [i.opened, i.blocking, i.modal, i.background, i.mm(t.opts[n].position), i.mm(t.opts[n].zposition)];
o.$html.removeClass(a.join(" ")), o.$page.each(function () {
e(this).attr("style", e(this).data(s.style))
}), t.vars.opened = !1, t.trigger("close:finish")
}, this.conf.transitionDuration), this.trigger("close:start"), o.$html.removeClass(i.opening), this.trigger("close:after")
}
}, e[t].prototype.closeAllOthers = function () {
o.$allMenus.not(this.$menu).each(function () {
var n = e(this).data(t);
n && n.close && n.close()
})
}, e[t].prototype.setPage = function (t) {
this.trigger("setPage:before", t);
var s = this, a = this.conf[n];
t && t.length || (t = o.$body.find(a.pageSelector), a.noPageSelector.length && (t = t.not(a.noPageSelector.join(", "))), t.length > 1 && a.wrapPageIfNeeded && (t = t.wrapAll("<" + this.conf[n].pageNodetype + " />").parent())), t.each(function () {
e(this).attr("id", e(this).attr("id") || s.__getUniqueId())
}), t.addClass(i.page + " " + i.slideout), o.$page = t, this.trigger("setPage:after", t)
}, e[t].prototype["_initWindow_" + n] = function () {
o.$wndw.off(a.keydown + "-" + n).on(a.keydown + "-" + n, function (e) {
if (o.$html.hasClass(i.opened) && 9 == e.keyCode) return e.preventDefault(), !1
});
var e = 0;
o.$wndw.off(a.resize + "-" + n).on(a.resize + "-" + n, function (t, n) {
if (1 == o.$page.length && (n || o.$html.hasClass(i.opened))) {
var s = o.$wndw.height();
(n || s != e) && (e = s, o.$page.css("minHeight", s))
}
})
}, e[t].prototype._initBlocker = function () {
var t = this;
this.opts[n].blockUI && (o.$blck || (o.$blck = e('')), o.$blck.appendTo(o.$body).off(a.touchstart + "-" + n + " " + a.touchmove + "-" + n).on(a.touchstart + "-" + n + " " + a.touchmove + "-" + n, function (e) {
e.preventDefault(), e.stopPropagation(), o.$blck.trigger(a.mousedown + "-" + n)
}).off(a.mousedown + "-" + n).on(a.mousedown + "-" + n, function (e) {
e.preventDefault(), o.$html.hasClass(i.modal) || (t.closeAllOthers(), t.close())
}))
};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu scrollBugFix add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "scrollBugFix";
e[t].addons[n] = {
setup: function () {
var s = this.opts[n];
this.conf[n];
o = e[t].glbl, e[t].support.touch && this.opts.offCanvas && this.opts.offCanvas.blockUI && ("boolean" == typeof s && (s = {fix: s}), "object" != typeof s && (s = {}), s = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], s), s.fix && (this.bind("open:start", function () {
this.$pnls.children("." + i.opened).scrollTop(0)
}), this.bind("initMenu:after", function () {
this["_initWindow_" + n]()
})))
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e
}, clickAnchor: function (e, t) {
}
}, e[t].defaults[n] = {fix: !0}, e[t].prototype["_initWindow_" + n] = function () {
o.$docu.off(a.touchmove + "-" + n).on(a.touchmove + "-" + n, function (e) {
o.$html.hasClass(i.opened) && e.preventDefault()
});
var t = !1;
o.$body.off(a.touchstart + "-" + n).on(a.touchstart + "-" + n, "." + i.panels + "> ." + i.opened, function (e) {
o.$html.hasClass(i.opened) && (t || (t = !0, 0 === e.currentTarget.scrollTop ? e.currentTarget.scrollTop = 1 : e.currentTarget.scrollHeight === e.currentTarget.scrollTop + e.currentTarget.offsetHeight && (e.currentTarget.scrollTop -= 1), t = !1))
}).off(a.touchmove + "-" + n).on(a.touchmove + "-" + n, "." + i.panels + "> ." + i.opened, function (t) {
o.$html.hasClass(i.opened) && e(this)[0].scrollHeight > e(this).innerHeight() && t.stopPropagation()
}), o.$wndw.off(a.orientationchange + "-" + n).on(a.orientationchange + "-" + n, function () {
that.$pnls.children("." + i.opened).scrollTop(0).css({"-webkit-overflow-scrolling": "auto"}).css({"-webkit-overflow-scrolling": "touch"})
})
};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu screenReader add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "screenReader";
e[t].addons[n] = {
setup: function () {
var s = this, a = this.opts[n], r = this.conf[n];
o = e[t].glbl, "boolean" == typeof a && (a = {
aria: a,
text: a
}), "object" != typeof a && (a = {}), a = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], a), a.aria && (this.bind("initAddons:after", function () {
this.bind("initMenu:after", function () {
this.trigger("initMenu:after:sr-aria")
}), this.bind("initNavbar:after", function () {
this.trigger("initNavbar:after:sr-aria", arguments[0])
}), this.bind("openPanel:start", function () {
this.trigger("openPanel:start:sr-aria", arguments[0])
}), this.bind("close:start", function () {
this.trigger("close:start:sr-aria")
}), this.bind("close:finish", function () {
this.trigger("close:finish:sr-aria")
}), this.bind("open:start", function () {
this.trigger("open:start:sr-aria")
}), this.bind("open:finish", function () {
this.trigger("open:finish:sr-aria")
})
}), this.bind("updateListview", function () {
this.$pnls.find("." + i.listview).children().each(function () {
s.__sr_aria(e(this), "hidden", e(this).is("." + i.hidden))
})
}), this.bind("openPanel:start", function (e) {
var t = this.$menu.find("." + i.panel).not(e).not(e.parents("." + i.panel)),
n = e.add(e.find("." + i.vertical + "." + i.opened).children("." + i.panel));
this.__sr_aria(t, "hidden", !0), this.__sr_aria(n, "hidden", !1)
}), this.bind("closePanel", function (e) {
this.__sr_aria(e, "hidden", !0)
}), this.bind("initPanels:after", function (t) {
var n = t.find("." + i.prev + ", ." + i.next).each(function () {
s.__sr_aria(e(this), "owns", e(this).attr("href").replace("#", ""))
});
this.__sr_aria(n, "haspopup", !0)
}), this.bind("initNavbar:after", function (e) {
var t = e.children("." + i.navbar);
this.__sr_aria(t, "hidden", !e.hasClass(i.hasnavbar))
}), a.text && (this.bind("initlistview:after", function (e) {
var t = e.find("." + i.listview).find("." + i.fullsubopen).parent().children("span");
this.__sr_aria(t, "hidden", !0)
}), "parent" == this.opts.navbar.titleLink && this.bind("initNavbar:after", function (e) {
var t = e.children("." + i.navbar), n = !!t.children("." + i.prev).length;
this.__sr_aria(t.children("." + i.title), "hidden", n)
}))), a.text && (this.bind("initAddons:after", function () {
this.bind("setPage:after", function () {
this.trigger("setPage:after:sr-text", arguments[0])
})
}), this.bind("initNavbar:after", function (n) {
var s = n.children("." + i.navbar), a = s.children("." + i.title).text(),
o = e[t].i18n(r.text.closeSubmenu);
a && (o += " (" + a + ")"), s.children("." + i.prev).html(this.__sr_text(o))
}), this.bind("initlistview:after", function (n) {
n.find("." + i.listview).children("li").children("." + i.next).each(function () {
var n = e(this), a = $prev.nextAll("span, a").first().text(),
o = e[t].i18n(r.text[$prev.parent().is("." + i.vertical) ? "toggleSubmenu" : "openSubmenu"]);
a && (o += " (" + a + ")"), n.html(s.__sr_text(o))
})
}))
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("sronly")
}, clickAnchor: function (e, t) {
}
}, e[t].defaults[n] = {aria: !0, text: !0}, e[t].configuration[n] = {
text: {
closeMenu: "Close menu",
closeSubmenu: "Close submenu",
openSubmenu: "Open submenu",
toggleSubmenu: "Toggle submenu"
}
}, e[t].prototype.__sr_aria = function (e, t, n) {
e.prop("aria-" + t, n)[n ? "attr" : "removeAttr"]("aria-" + t, n)
}, e[t].prototype.__sr_text = function (e) {
return '' + e + ""
};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu autoHeight add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "autoHeight";
e[t].addons[n] = {
setup: function () {
var s = this.opts[n];
this.conf[n];
if (o = e[t].glbl, "boolean" == typeof s && s && (s = {height: "auto"}), "string" == typeof s && (s = {height: s}), "object" != typeof s && (s = {}), s = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], s), "auto" == s.height || "highest" == s.height) {
this.bind("initMenu:after", function () {
this.$menu.addClass(i.autoheight)
});
var a = function (t) {
if (!this.opts.offCanvas || this.vars.opened) {
var n = Math.max(parseInt(this.$pnls.css("top"), 10), 0) || 0,
a = Math.max(parseInt(this.$pnls.css("bottom"), 10), 0) || 0, o = 0;
this.$menu.addClass(i.measureheight), "auto" == s.height ? (t = t || this.$pnls.children("." + i.opened), t.is("." + i.vertical) && (t = t.parents("." + i.panel).not("." + i.vertical).first()), o = t.outerHeight()) : "highest" == s.height && this.$pnls.children().each(function () {
var t = e(this);
t.is("." + i.vertical) && (t = t.parents("." + i.panel).not("." + i.vertical).first()), o = Math.max(o, t.outerHeight())
}), this.$menu.height(o + n + a).removeClass(i.measureheight)
}
};
this.opts.offCanvas && this.bind("open:start", a), "highest" == s.height && this.bind("initPanels:after", a), "auto" == s.height && (this.bind("updateListview", a), this.bind("openPanel:start", a), this.bind("closePanel:finish", a))
}
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("autoheight measureheight"), a.add("resize")
}, clickAnchor: function (e, t) {
}
}, e[t].defaults[n] = {height: "default"};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu backButton add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "backButton";
e[t].addons[n] = {
setup: function () {
if (this.opts.offCanvas) {
var s = this, a = this.opts[n];
this.conf[n];
if (o = e[t].glbl, "boolean" == typeof a && (a = {close: a}), "object" != typeof a && (a = {}), a = e.extend(!0, {}, e[t].defaults[n], a), a.close) {
var r = "#" + s.$menu.attr("id");
this.bind("open:finish", function (e) {
location.hash != r && history.pushState(null, document.title, r)
}), e(window).on("popstate", function (e) {
o.$html.hasClass(i.opened) ? (e.stopPropagation(), s.close()) : location.hash == r && (e.stopPropagation(), s.open())
})
}
}
}, add: function () {
return window.history && window.history.pushState ? (i = e[t]._c, s = e[t]._d, void (a = e[t]._e)) : void (e[t].addons[n].setup = function () {
})
}, clickAnchor: function (e, t) {
}
}, e[t].defaults[n] = {close: !1};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu columns add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "columns";
e[t].addons[n] = {
setup: function () {
var s = this.opts[n];
this.conf[n];
if (o = e[t].glbl, "boolean" == typeof s && (s = {add: s}), "number" == typeof s && (s = {
add: !0,
visible: s
}), "object" != typeof s && (s = {}), "number" == typeof s.visible && (s.visible = {
min: s.visible,
max: s.visible
}), s = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], s), s.add) {
s.visible.min = Math.max(1, Math.min(6, s.visible.min)), s.visible.max = Math.max(s.visible.min, Math.min(6, s.visible.max));
for (var a = this.opts.offCanvas ? this.$menu.add(o.$html) : this.$menu, r = [], l = 0; l <= s.visible.max; l++) r.push(i.columns + "-" + l);
r = r.join(" ");
var d = function (e) {
var t = this.$pnls.children("." + i.subopened).length;
e && !e.hasClass(i.subopened) && t++, t = Math.min(s.visible.max, Math.max(s.visible.min, t)), a.removeClass(r).addClass(i.columns + "-" + t)
}, c = function () {
a.removeClass(r)
}, h = function (t) {
this.$pnls.children("." + i.panel).removeClass(r).filter("." + i.subopened).add(t).slice(-s.visible.max).each(function (t) {
e(this).addClass(i.columns + "-" + t)
})
};
this.bind("initMenu:after", function () {
this.$menu.addClass(i.columns)
}), this.bind("initPanels:after", function (e) {
h.call(this, this.$pnls.children("." + i.opened))
}), this.bind("open:start", d), this.bind("openPanel:start", d), this.bind("openPanel:start", h), this.bind("close:finish", c), this.opts.offCanvas || openMenu.call(this)
}
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("columns")
}, clickAnchor: function (t, s) {
if (!this.opts[n].add) return !1;
if (s) {
var a = t.attr("href");
if (a.length > 1 && "#" == a.slice(0, 1)) try {
var o = e(a, this.$menu);
if (o.is("." + i.panel)) for (var r = parseInt(t.closest("." + i.panel).attr("class").split(i.columns + "-")[1].split(" ")[0], 10) + 1; r !== !1;) {
var l = this.$pnls.children("." + i.columns + "-" + r);
if (!l.length) {
r = !1;
break
}
r++, l.removeClass(i.subopened).removeClass(i.opened).removeClass(i.highest).addClass(i.hidden)
}
} catch (d) {
}
}
}
}, e[t].defaults[n] = {add: !1, visible: {min: 1, max: 3}};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu dividers add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "dividers";
e[t].addons[n] = {
setup: function () {
var s = this, r = this.opts[n];
this.conf[n];
if (o = e[t].glbl, "boolean" == typeof r && (r = {
add: r,
fixed: r
}), "object" != typeof r && (r = {}), r = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], r), this.bind("initListview:after", function (e) {
this.__refactorClass(e.find("li"), this.conf.classNames[n].collapsed, "collapsed")
}), r.add && this.bind("initListview:after", function (t) {
var n;
switch (r.addTo) {
case"panels":
n = t;
break;
default:
n = t.filter(r.addTo)
}
n.length && n.find("." + i.listview).find("." + i.divider).remove().end().each(function () {
var t = "";
s.__filterListItems(e(this).children()).each(function () {
var n = e.trim(e(this).children("a, span").text()).slice(0, 1).toLowerCase();
n != t && n.length && (t = n, e('
")), i = i.add(t))
}), i.find("." + s.next).remove(), f.children("." + s.listview).append(i), this.openPanel(f)
} else e(n.get().reverse()).each(function (t) {
var n = e(this), i = n.data(a.parent);
i && (l.__filterListItems(n.find("." + s.listview).children()).length ? (i.hasClass(s.hidden) && i.children("." + s.next).not("." + s.fullsubopen).addClass(s.fullsubopen).addClass(s.fullsubopensearch), i.removeClass(s.hidden).removeClass(s.nosubresults).prevAll("." + s.divider).first().removeClass(s.hidden)) : h || (n.hasClass(s.opened) && setTimeout(function () {
l.openPanel(i.closest("." + s.panel))
}, (t + 1) * (1.5 * l.conf.openingInterval)), i.addClass(s.nosubresults)))
});
r.find("." + s.noresultsmsg)[m.not("." + s.hidden).length ? "addClass" : "removeClass"](s.hidden), this.trigger("updateListview")
}
};
u.off(o.keyup + "-" + i + " " + o.change + "-" + i).on(o.keyup + "-" + i, function (e) {
t(e.keyCode) || C.call(l)
}).on(o.change + "-" + i, function (e) {
C.call(l)
});
var y = c.children("." + s.btn);
y.length && u.on(o.keyup + "-" + i, function (e) {
y[u.val().length ? "removeClass" : "addClass"](s.hidden)
}), u.trigger(o.keyup + "-" + i)
})
}
}
})
}, add: function () {
s = e[n]._c, a = e[n]._d, o = e[n]._e, s.add("clear search hassearch resultspanel noresultsmsg noresults nosubresults fullsubopensearch"), a.add("searchtext"), o.add("change keyup")
}, clickAnchor: function (e, t) {
}
}, e[n].defaults[i] = {
add: !1,
addTo: "panels",
placeholder: "Search",
noResults: "No results found.",
resultsPanel: {add: !1, dividers: !0, title: "Search results"},
search: !0,
showTextItems: !1,
showSubPanels: !0
}, e[n].configuration[i] = {clear: !1, form: !1, input: !1, submit: !1};
var s, a, o, r
}(jQuery),/*
* jQuery mmenu sectionIndexer add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "sectionIndexer";
e[t].addons[n] = {
setup: function () {
var s = this, r = this.opts[n];
this.conf[n];
o = e[t].glbl, "boolean" == typeof r && (r = {add: r}), "object" != typeof r && (r = {}), r = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], r), this.bind("initPanels:after", function (t) {
if (r.add) {
var o;
switch (r.addTo) {
case"panels":
o = t;
break;
default:
o = e(r.addTo, this.$menu).filter("." + i.panel)
}
o.find("." + i.divider).closest("." + i.panel).addClass(i.hasindexer), this.$indexer || (this.$indexer = e('').prependTo(this.$pnls).append('abcdefghijklmnopqrstuvwxyz'), this.$indexer.children().on(a.mouseover + "-" + n + " " + i.touchstart + "-" + n, function (t) {
var n = e(this).attr("href").slice(1), a = s.$pnls.children("." + i.opened),
o = a.find("." + i.listview), r = !1, l = a.scrollTop();
a.scrollTop(0), o.children("." + i.divider).not("." + i.hidden).each(function () {
r === !1 && n == e(this).text().slice(0, 1).toLowerCase() && (r = e(this).position().top)
}), a.scrollTop(r !== !1 ? r : l)
}));
var l = function (e) {
e = e || this.$pnls.children("." + i.opened), this.$menu[(e.hasClass(i.hasindexer) ? "add" : "remove") + "Class"](i.hasindexer)
};
this.bind("openPanel:start", l), this.bind("initPanels:after", l)
}
})
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("indexer hasindexer"), a.add("mouseover touchstart")
}, clickAnchor: function (e, t) {
if (e.parent().is("." + i.indexer)) return !0
}
}, e[t].defaults[n] = {add: !1, addTo: "panels"};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu setSelected add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "setSelected";
e[t].addons[n] = {
setup: function () {
var a = this, r = this.opts[n];
this.conf[n];
if (o = e[t].glbl, "boolean" == typeof r && (r = {
hover: r,
parent: r
}), "object" != typeof r && (r = {}), r = this.opts[n] = e.extend(!0, {}, e[t].defaults[n], r), "detect" == r.current) {
var l = function (e) {
e = e.split("?")[0].split("#")[0];
var t = a.$menu.find('a[href="' + e + '"], a[href="' + e + '/"]');
t.length ? a.setSelected(t.parent(), !0) : (e = e.split("/").slice(0, -1), e.length && l(e.join("/")))
};
this.bind("initMenu:after", function () {
l(window.location.href)
})
} else r.current || this.bind("initListview:after", function (e) {
$panels.find("." + i.listview).children("." + i.selected).removeClass(i.selected)
});
r.hover && this.bind("initMenu:after", function () {
this.$menu.addClass(i.hoverselected)
}), r.parent && (this.bind("openPanel:finish", function (e) {
this.$pnls.find("." + i.listview).find("." + i.next).removeClass(i.selected);
for (var t = e.data(s.parent); t;) t.not("." + i.vertical).children("." + i.next).addClass(i.selected), t = t.closest("." + i.panel).data(s.parent)
}), this.bind("initMenu:after", function () {
this.$menu.addClass(i.parentselected)
}))
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("hoverselected parentselected")
}, clickAnchor: function (e, t) {
}
}, e[t].defaults[n] = {current: !0, hover: !1, parent: !1};
var i, s, a, o
}(jQuery),/*
* jQuery mmenu toggles add-on
* mmenu.frebsite.nl
*
* Copyright (c) Fred Heusschen
*/
function (e) {
var t = "mmenu", n = "toggles";
e[t].addons[n] = {
setup: function () {
var s = this;
this.opts[n], this.conf[n];
o = e[t].glbl, this.bind("initListview:after", function (t) {
this.__refactorClass(t.find("input"), this.conf.classNames[n].toggle, "toggle"), this.__refactorClass(t.find("input"), this.conf.classNames[n].check, "check"), t.find("input." + i.toggle + ", input." + i.check).each(function () {
var t = e(this), n = t.closest("li"), a = t.hasClass(i.toggle) ? "toggle" : "check",
o = t.attr("id") || s.__getUniqueId();
n.children('label[for="' + o + '"]').length || (t.attr("id", o), n.prepend(t), e('').insertBefore(n.children("a, span").last()))
})
})
}, add: function () {
i = e[t]._c, s = e[t]._d, a = e[t]._e, i.add("toggle check")
}, clickAnchor: function (e, t) {
}
}, e[t].configuration.classNames[n] = {toggle: "Toggle", check: "Check"};
var i, s, a, o
}(jQuery);
return true;
}));
!function (i) {
"use strict";
"function" == typeof define && define.amd ? define(["jquery"], i) : "undefined" != typeof exports ? module.exports = i(require("jquery")) : i(jQuery)
}(function (i) {
"use strict";
var e = window.Slick || {};
(e = function () {
var e = 0;
return function (t, o) {
var s, n = this;
n.defaults = {
accessibility: !0,
adaptiveHeight: !1,
appendArrows: i(t),
appendDots: i(t),
arrows: !0,
asNavFor: null,
prevArrow: '',
nextArrow: '',
autoplay: !1,
autoplaySpeed: 3e3,
centerMode: !1,
centerPadding: "50px",
cssEase: "ease",
customPaging: function (e, t) {
return i('').text(t + 1)
},
dots: !1,
dotsClass: "slick-dots",
draggable: !0,
easing: "linear",
edgeFriction: .35,
fade: !1,
focusOnSelect: !1,
focusOnChange: !1,
infinite: !0,
initialSlide: 0,
lazyLoad: "ondemand",
mobileFirst: !1,
pauseOnHover: !0,
pauseOnFocus: !0,
pauseOnDotsHover: !1,
respondTo: "window",
responsive: null,
rows: 1,
rtl: !1,
slide: "",
slidesPerRow: 1,
slidesToShow: 1,
slidesToScroll: 1,
speed: 500,
swipe: !0,
swipeToSlide: !1,
touchMove: !0,
touchThreshold: 5,
useCSS: !0,
useTransform: !0,
variableWidth: !1,
vertical: !1,
verticalSwiping: !1,
waitForAnimate: !0,
zIndex: 1e3
}, n.initials = {
animating: !1,
dragging: !1,
autoPlayTimer: null,
currentDirection: 0,
currentLeft: null,
currentSlide: 0,
direction: 1,
$dots: null,
listWidth: null,
listHeight: null,
loadIndex: 0,
$nextArrow: null,
$prevArrow: null,
scrolling: !1,
slideCount: null,
slideWidth: null,
$slideTrack: null,
$slides: null,
sliding: !1,
slideOffset: 0,
swipeLeft: null,
swiping: !1,
$list: null,
touchObject: {},
transformsEnabled: !1,
unslicked: !1
}, i.extend(n, n.initials), n.activeBreakpoint = null, n.animType = null, n.animProp = null, n.breakpoints = [], n.breakpointSettings = [], n.cssTransitions = !1, n.focussed = !1, n.interrupted = !1, n.hidden = "hidden", n.paused = !0, n.positionProp = null, n.respondTo = null, n.rowCount = 1, n.shouldClick = !0, n.$slider = i(t), n.$slidesCache = null, n.transformType = null, n.transitionType = null, n.visibilityChange = "visibilitychange", n.windowWidth = 0, n.windowTimer = null, s = i(t).data("slick") || {}, n.options = i.extend({}, n.defaults, o, s), n.currentSlide = n.options.initialSlide, n.originalSettings = n.options, void 0 !== document.mozHidden ? (n.hidden = "mozHidden", n.visibilityChange = "mozvisibilitychange") : void 0 !== document.webkitHidden && (n.hidden = "webkitHidden", n.visibilityChange = "webkitvisibilitychange"), n.autoPlay = i.proxy(n.autoPlay, n), n.autoPlayClear = i.proxy(n.autoPlayClear, n), n.autoPlayIterator = i.proxy(n.autoPlayIterator, n), n.changeSlide = i.proxy(n.changeSlide, n), n.clickHandler = i.proxy(n.clickHandler, n), n.selectHandler = i.proxy(n.selectHandler, n), n.setPosition = i.proxy(n.setPosition, n), n.swipeHandler = i.proxy(n.swipeHandler, n), n.dragHandler = i.proxy(n.dragHandler, n), n.keyHandler = i.proxy(n.keyHandler, n), n.instanceUid = e++, n.htmlExpr = /^(?:\s*(<[\w\W]+>)[^>]*)$/, n.registerBreakpoints(), n.init(!0)
}
}()).prototype.activateADA = function () {
this.$slideTrack.find(".slick-active").attr({"aria-hidden": "false"}).find("a, input, button, select").attr({tabindex: "0"})
}, e.prototype.addSlide = e.prototype.slickAdd = function (e, t, o) {
var s = this;
if ("boolean" == typeof t) o = t, t = null; else if (t < 0 || t >= s.slideCount) return !1;
s.unload(), "number" == typeof t ? 0 === t && 0 === s.$slides.length ? i(e).appendTo(s.$slideTrack) : o ? i(e).insertBefore(s.$slides.eq(t)) : i(e).insertAfter(s.$slides.eq(t)) : !0 === o ? i(e).prependTo(s.$slideTrack) : i(e).appendTo(s.$slideTrack), s.$slides = s.$slideTrack.children(this.options.slide), s.$slideTrack.children(this.options.slide).detach(), s.$slideTrack.append(s.$slides), s.$slides.each(function (e, t) {
i(t).attr("data-slick-index", e)
}), s.$slidesCache = s.$slides, s.reinit()
}, e.prototype.animateHeight = function () {
var i = this;
if (1 === i.options.slidesToShow && !0 === i.options.adaptiveHeight && !1 === i.options.vertical) {
var e = i.$slides.eq(i.currentSlide).outerHeight(!0);
i.$list.animate({height: e}, i.options.speed)
}
}, e.prototype.animateSlide = function (e, t) {
var o = {}, s = this;
s.animateHeight(), !0 === s.options.rtl && !1 === s.options.vertical && (e = -e), !1 === s.transformsEnabled ? !1 === s.options.vertical ? s.$slideTrack.animate({left: e}, s.options.speed, s.options.easing, t) : s.$slideTrack.animate({top: e}, s.options.speed, s.options.easing, t) : !1 === s.cssTransitions ? (!0 === s.options.rtl && (s.currentLeft = -s.currentLeft), i({animStart: s.currentLeft}).animate({animStart: e}, {
duration: s.options.speed,
easing: s.options.easing,
step: function (i) {
i = Math.ceil(i), !1 === s.options.vertical ? (o[s.animType] = "translate(" + i + "px, 0px)", s.$slideTrack.css(o)) : (o[s.animType] = "translate(0px," + i + "px)", s.$slideTrack.css(o))
},
complete: function () {
t && t.call()
}
})) : (s.applyTransition(), e = Math.ceil(e), !1 === s.options.vertical ? o[s.animType] = "translate3d(" + e + "px, 0px, 0px)" : o[s.animType] = "translate3d(0px," + e + "px, 0px)", s.$slideTrack.css(o), t && setTimeout(function () {
s.disableTransition(), t.call()
}, s.options.speed))
}, e.prototype.getNavTarget = function () {
var e = this, t = e.options.asNavFor;
return t && null !== t && (t = i(t).not(e.$slider)), t
}, e.prototype.asNavFor = function (e) {
var t = this.getNavTarget();
null !== t && "object" == typeof t && t.each(function () {
var t = i(this).slick("getSlick");
t.unslicked || t.slideHandler(e, !0)
})
}, e.prototype.applyTransition = function (i) {
var e = this, t = {};
!1 === e.options.fade ? t[e.transitionType] = e.transformType + " " + e.options.speed + "ms " + e.options.cssEase : t[e.transitionType] = "opacity " + e.options.speed + "ms " + e.options.cssEase, !1 === e.options.fade ? e.$slideTrack.css(t) : e.$slides.eq(i).css(t)
}, e.prototype.autoPlay = function () {
var i = this;
i.autoPlayClear(), i.slideCount > i.options.slidesToShow && (i.autoPlayTimer = setInterval(i.autoPlayIterator, i.options.autoplaySpeed))
}, e.prototype.autoPlayClear = function () {
var i = this;
i.autoPlayTimer && clearInterval(i.autoPlayTimer)
}, e.prototype.autoPlayIterator = function () {
var i = this, e = i.currentSlide + i.options.slidesToScroll;
i.paused || i.interrupted || i.focussed || (!1 === i.options.infinite && (1 === i.direction && i.currentSlide + 1 === i.slideCount - 1 ? i.direction = 0 : 0 === i.direction && (e = i.currentSlide - i.options.slidesToScroll, i.currentSlide - 1 == 0 && (i.direction = 1))), i.slideHandler(e))
}, e.prototype.buildArrows = function () {
var e = this;
!0 === e.options.arrows && (e.$prevArrow = i(e.options.prevArrow).addClass("slick-arrow"), e.$nextArrow = i(e.options.nextArrow).addClass("slick-arrow"), e.slideCount > e.options.slidesToShow ? (e.$prevArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"), e.$nextArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"), e.htmlExpr.test(e.options.prevArrow) && e.$prevArrow.prependTo(e.options.appendArrows), e.htmlExpr.test(e.options.nextArrow) && e.$nextArrow.appendTo(e.options.appendArrows), !0 !== e.options.infinite && e.$prevArrow.addClass("slick-disabled").attr("aria-disabled", "true")) : e.$prevArrow.add(e.$nextArrow).addClass("slick-hidden").attr({
"aria-disabled": "true",
tabindex: "-1"
}))
}, e.prototype.buildDots = function () {
var e, t, o = this;
if (!0 === o.options.dots) {
for (o.$slider.addClass("slick-dotted"), t = i("
").addClass(o.options.dotsClass), e = 0; e <= o.getDotCount(); e += 1) t.append(i("").append(o.options.customPaging.call(this, o, e)));
o.$dots = t.appendTo(o.options.appendDots), o.$dots.find("li").first().addClass("slick-active")
}
}, e.prototype.buildOut = function () {
var e = this;
e.$slides = e.$slider.children(e.options.slide + ":not(.slick-cloned)").addClass("slick-slide"), e.slideCount = e.$slides.length, e.$slides.each(function (e, t) {
i(t).attr("data-slick-index", e).data("originalStyling", i(t).attr("style") || "")
}), e.$slider.addClass("slick-slider"), e.$slideTrack = 0 === e.slideCount ? i('').appendTo(e.$slider) : e.$slides.wrapAll('').parent(), e.$list = e.$slideTrack.wrap('').parent(), e.$slideTrack.css("opacity", 0), !0 !== e.options.centerMode && !0 !== e.options.swipeToSlide || (e.options.slidesToScroll = 1), i("img[data-lazy]", e.$slider).not("[src]").addClass("slick-loading"), e.setupInfinite(), e.buildArrows(), e.buildDots(), e.updateDots(), e.setSlideClasses("number" == typeof e.currentSlide ? e.currentSlide : 0), !0 === e.options.draggable && e.$list.addClass("draggable")
}, e.prototype.buildRows = function () {
var i, e, t, o, s, n, r, l = this;
if (o = document.createDocumentFragment(), n = l.$slider.children(), l.options.rows > 1) {
for (r = l.options.slidesPerRow * l.options.rows, s = Math.ceil(n.length / r), i = 0; i < s; i++) {
var d = document.createElement("div");
for (e = 0; e < l.options.rows; e++) {
var a = document.createElement("div");
for (t = 0; t < l.options.slidesPerRow; t++) {
var c = i * r + (e * l.options.slidesPerRow + t);
n.get(c) && a.appendChild(n.get(c))
}
d.appendChild(a)
}
o.appendChild(d)
}
l.$slider.empty().append(o), l.$slider.children().children().children().css({
width: 100 / l.options.slidesPerRow + "%",
display: "inline-block"
})
}
}, e.prototype.checkResponsive = function (e, t) {
var o, s, n, r = this, l = !1, d = r.$slider.width(), a = window.innerWidth || i(window).width();
if ("window" === r.respondTo ? n = a : "slider" === r.respondTo ? n = d : "min" === r.respondTo && (n = Math.min(a, d)), r.options.responsive && r.options.responsive.length && null !== r.options.responsive) {
s = null;
for (o in r.breakpoints) r.breakpoints.hasOwnProperty(o) && (!1 === r.originalSettings.mobileFirst ? n < r.breakpoints[o] && (s = r.breakpoints[o]) : n > r.breakpoints[o] && (s = r.breakpoints[o]));
null !== s ? null !== r.activeBreakpoint ? (s !== r.activeBreakpoint || t) && (r.activeBreakpoint = s, "unslick" === r.breakpointSettings[s] ? r.unslick(s) : (r.options = i.extend({}, r.originalSettings, r.breakpointSettings[s]), !0 === e && (r.currentSlide = r.options.initialSlide), r.refresh(e)), l = s) : (r.activeBreakpoint = s, "unslick" === r.breakpointSettings[s] ? r.unslick(s) : (r.options = i.extend({}, r.originalSettings, r.breakpointSettings[s]), !0 === e && (r.currentSlide = r.options.initialSlide), r.refresh(e)), l = s) : null !== r.activeBreakpoint && (r.activeBreakpoint = null, r.options = r.originalSettings, !0 === e && (r.currentSlide = r.options.initialSlide), r.refresh(e), l = s), e || !1 === l || r.$slider.trigger("breakpoint", [r, l])
}
}, e.prototype.changeSlide = function (e, t) {
var o, s, n, r = this, l = i(e.currentTarget);
switch (l.is("a") && e.preventDefault(), l.is("li") || (l = l.closest("li")), n = r.slideCount % r.options.slidesToScroll != 0, o = n ? 0 : (r.slideCount - r.currentSlide) % r.options.slidesToScroll, e.data.message) {
case"previous":
s = 0 === o ? r.options.slidesToScroll : r.options.slidesToShow - o, r.slideCount > r.options.slidesToShow && r.slideHandler(r.currentSlide - s, !1, t);
break;
case"next":
s = 0 === o ? r.options.slidesToScroll : o, r.slideCount > r.options.slidesToShow && r.slideHandler(r.currentSlide + s, !1, t);
break;
case"index":
var d = 0 === e.data.index ? 0 : e.data.index || l.index() * r.options.slidesToScroll;
r.slideHandler(r.checkNavigable(d), !1, t), l.children().trigger("focus");
break;
default:
return
}
}, e.prototype.checkNavigable = function (i) {
var e, t;
if (e = this.getNavigableIndexes(), t = 0, i > e[e.length - 1]) i = e[e.length - 1]; else for (var o in e) {
if (i < e[o]) {
i = t;
break
}
t = e[o]
}
return i
}, e.prototype.cleanUpEvents = function () {
var e = this;
e.options.dots && null !== e.$dots && (i("li", e.$dots).off("click.slick", e.changeSlide).off("mouseenter.slick", i.proxy(e.interrupt, e, !0)).off("mouseleave.slick", i.proxy(e.interrupt, e, !1)), !0 === e.options.accessibility && e.$dots.off("keydown.slick", e.keyHandler)), e.$slider.off("focus.slick blur.slick"), !0 === e.options.arrows && e.slideCount > e.options.slidesToShow && (e.$prevArrow && e.$prevArrow.off("click.slick", e.changeSlide), e.$nextArrow && e.$nextArrow.off("click.slick", e.changeSlide), !0 === e.options.accessibility && (e.$prevArrow && e.$prevArrow.off("keydown.slick", e.keyHandler), e.$nextArrow && e.$nextArrow.off("keydown.slick", e.keyHandler))), e.$list.off("touchstart.slick mousedown.slick", e.swipeHandler), e.$list.off("touchmove.slick mousemove.slick", e.swipeHandler), e.$list.off("touchend.slick mouseup.slick", e.swipeHandler), e.$list.off("touchcancel.slick mouseleave.slick", e.swipeHandler), e.$list.off("click.slick", e.clickHandler), i(document).off(e.visibilityChange, e.visibility), e.cleanUpSlideEvents(), !0 === e.options.accessibility && e.$list.off("keydown.slick", e.keyHandler), !0 === e.options.focusOnSelect && i(e.$slideTrack).children().off("click.slick", e.selectHandler), i(window).off("orientationchange.slick.slick-" + e.instanceUid, e.orientationChange), i(window).off("resize.slick.slick-" + e.instanceUid, e.resize), i("[draggable!=true]", e.$slideTrack).off("dragstart", e.preventDefault), i(window).off("load.slick.slick-" + e.instanceUid, e.setPosition)
}, e.prototype.cleanUpSlideEvents = function () {
var e = this;
e.$list.off("mouseenter.slick", i.proxy(e.interrupt, e, !0)), e.$list.off("mouseleave.slick", i.proxy(e.interrupt, e, !1))
}, e.prototype.cleanUpRows = function () {
var i, e = this;
e.options.rows > 1 && ((i = e.$slides.children().children()).removeAttr("style"), e.$slider.empty().append(i))
}, e.prototype.clickHandler = function (i) {
!1 === this.shouldClick && (i.stopImmediatePropagation(), i.stopPropagation(), i.preventDefault())
}, e.prototype.destroy = function (e) {
var t = this;
t.autoPlayClear(), t.touchObject = {}, t.cleanUpEvents(), i(".slick-cloned", t.$slider).detach(), t.$dots && t.$dots.remove(), t.$prevArrow && t.$prevArrow.length && (t.$prevArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display", ""), t.htmlExpr.test(t.options.prevArrow) && t.$prevArrow.remove()), t.$nextArrow && t.$nextArrow.length && (t.$nextArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display", ""), t.htmlExpr.test(t.options.nextArrow) && t.$nextArrow.remove()), t.$slides && (t.$slides.removeClass("slick-slide slick-active slick-center slick-visible slick-current").removeAttr("aria-hidden").removeAttr("data-slick-index").each(function () {
i(this).attr("style", i(this).data("originalStyling"))
}), t.$slideTrack.children(this.options.slide).detach(), t.$slideTrack.detach(), t.$list.detach(), t.$slider.append(t.$slides)), t.cleanUpRows(), t.$slider.removeClass("slick-slider"), t.$slider.removeClass("slick-initialized"), t.$slider.removeClass("slick-dotted"), t.unslicked = !0, e || t.$slider.trigger("destroy", [t])
}, e.prototype.disableTransition = function (i) {
var e = this, t = {};
t[e.transitionType] = "", !1 === e.options.fade ? e.$slideTrack.css(t) : e.$slides.eq(i).css(t)
}, e.prototype.fadeSlide = function (i, e) {
var t = this;
!1 === t.cssTransitions ? (t.$slides.eq(i).css({zIndex: t.options.zIndex}), t.$slides.eq(i).animate({opacity: 1}, t.options.speed, t.options.easing, e)) : (t.applyTransition(i), t.$slides.eq(i).css({
opacity: 1,
zIndex: t.options.zIndex
}), e && setTimeout(function () {
t.disableTransition(i), e.call()
}, t.options.speed))
}, e.prototype.fadeSlideOut = function (i) {
var e = this;
!1 === e.cssTransitions ? e.$slides.eq(i).animate({
opacity: 0,
zIndex: e.options.zIndex - 2
}, e.options.speed, e.options.easing) : (e.applyTransition(i), e.$slides.eq(i).css({
opacity: 0,
zIndex: e.options.zIndex - 2
}))
}, e.prototype.filterSlides = e.prototype.slickFilter = function (i) {
var e = this;
null !== i && (e.$slidesCache = e.$slides, e.unload(), e.$slideTrack.children(this.options.slide).detach(), e.$slidesCache.filter(i).appendTo(e.$slideTrack), e.reinit())
}, e.prototype.focusHandler = function () {
var e = this;
e.$slider.off("focus.slick blur.slick").on("focus.slick blur.slick", "*", function (t) {
t.stopImmediatePropagation();
var o = i(this);
setTimeout(function () {
e.options.pauseOnFocus && (e.focussed = o.is(":focus"), e.autoPlay())
}, 0)
})
}, e.prototype.getCurrent = e.prototype.slickCurrentSlide = function () {
return this.currentSlide
}, e.prototype.getDotCount = function () {
var i = this, e = 0, t = 0, o = 0;
if (!0 === i.options.infinite) if (i.slideCount <= i.options.slidesToShow) ++o; else for (; e < i.slideCount;) ++o, e = t + i.options.slidesToScroll, t += i.options.slidesToScroll <= i.options.slidesToShow ? i.options.slidesToScroll : i.options.slidesToShow; else if (!0 === i.options.centerMode) o = i.slideCount; else if (i.options.asNavFor) for (; e < i.slideCount;) ++o, e = t + i.options.slidesToScroll, t += i.options.slidesToScroll <= i.options.slidesToShow ? i.options.slidesToScroll : i.options.slidesToShow; else o = 1 + Math.ceil((i.slideCount - i.options.slidesToShow) / i.options.slidesToScroll);
return o - 1
}, e.prototype.getLeft = function (i) {
var e, t, o, s, n = this, r = 0;
return n.slideOffset = 0, t = n.$slides.first().outerHeight(!0), !0 === n.options.infinite ? (n.slideCount > n.options.slidesToShow && (n.slideOffset = n.slideWidth * n.options.slidesToShow * -1, s = -1, !0 === n.options.vertical && !0 === n.options.centerMode && (2 === n.options.slidesToShow ? s = -1.5 : 1 === n.options.slidesToShow && (s = -2)), r = t * n.options.slidesToShow * s), n.slideCount % n.options.slidesToScroll != 0 && i + n.options.slidesToScroll > n.slideCount && n.slideCount > n.options.slidesToShow && (i > n.slideCount ? (n.slideOffset = (n.options.slidesToShow - (i - n.slideCount)) * n.slideWidth * -1, r = (n.options.slidesToShow - (i - n.slideCount)) * t * -1) : (n.slideOffset = n.slideCount % n.options.slidesToScroll * n.slideWidth * -1, r = n.slideCount % n.options.slidesToScroll * t * -1))) : i + n.options.slidesToShow > n.slideCount && (n.slideOffset = (i + n.options.slidesToShow - n.slideCount) * n.slideWidth, r = (i + n.options.slidesToShow - n.slideCount) * t), n.slideCount <= n.options.slidesToShow && (n.slideOffset = 0, r = 0), !0 === n.options.centerMode && n.slideCount <= n.options.slidesToShow ? n.slideOffset = n.slideWidth * Math.floor(n.options.slidesToShow) / 2 - n.slideWidth * n.slideCount / 2 : !0 === n.options.centerMode && !0 === n.options.infinite ? n.slideOffset += n.slideWidth * Math.floor(n.options.slidesToShow / 2) - n.slideWidth : !0 === n.options.centerMode && (n.slideOffset = 0, n.slideOffset += n.slideWidth * Math.floor(n.options.slidesToShow / 2)), e = !1 === n.options.vertical ? i * n.slideWidth * -1 + n.slideOffset : i * t * -1 + r, !0 === n.options.variableWidth && (o = n.slideCount <= n.options.slidesToShow || !1 === n.options.infinite ? n.$slideTrack.children(".slick-slide").eq(i) : n.$slideTrack.children(".slick-slide").eq(i + n.options.slidesToShow), e = !0 === n.options.rtl ? o[0] ? -1 * (n.$slideTrack.width() - o[0].offsetLeft - o.width()) : 0 : o[0] ? -1 * o[0].offsetLeft : 0, !0 === n.options.centerMode && (o = n.slideCount <= n.options.slidesToShow || !1 === n.options.infinite ? n.$slideTrack.children(".slick-slide").eq(i) : n.$slideTrack.children(".slick-slide").eq(i + n.options.slidesToShow + 1), e = !0 === n.options.rtl ? o[0] ? -1 * (n.$slideTrack.width() - o[0].offsetLeft - o.width()) : 0 : o[0] ? -1 * o[0].offsetLeft : 0, e += (n.$list.width() - o.outerWidth()) / 2)), e
}, e.prototype.getOption = e.prototype.slickGetOption = function (i) {
return this.options[i]
}, e.prototype.getNavigableIndexes = function () {
var i, e = this, t = 0, o = 0, s = [];
for (!1 === e.options.infinite ? i = e.slideCount : (t = -1 * e.options.slidesToScroll, o = -1 * e.options.slidesToScroll, i = 2 * e.slideCount); t < i;) s.push(t), t = o + e.options.slidesToScroll, o += e.options.slidesToScroll <= e.options.slidesToShow ? e.options.slidesToScroll : e.options.slidesToShow;
return s
}, e.prototype.getSlick = function () {
return this
}, e.prototype.getSlideCount = function () {
var e, t, o = this;
return t = !0 === o.options.centerMode ? o.slideWidth * Math.floor(o.options.slidesToShow / 2) : 0, !0 === o.options.swipeToSlide ? (o.$slideTrack.find(".slick-slide").each(function (s, n) {
if (n.offsetLeft - t + i(n).outerWidth() / 2 > -1 * o.swipeLeft) return e = n, !1
}), Math.abs(i(e).attr("data-slick-index") - o.currentSlide) || 1) : o.options.slidesToScroll
}, e.prototype.goTo = e.prototype.slickGoTo = function (i, e) {
this.changeSlide({data: {message: "index", index: parseInt(i)}}, e)
}, e.prototype.init = function (e) {
var t = this;
i(t.$slider).hasClass("slick-initialized") || (i(t.$slider).addClass("slick-initialized"), t.buildRows(), t.buildOut(), t.setProps(), t.startLoad(), t.loadSlider(), t.initializeEvents(), t.updateArrows(), t.updateDots(), t.checkResponsive(!0), t.focusHandler()), e && t.$slider.trigger("init", [t]), !0 === t.options.accessibility && t.initADA(), t.options.autoplay && (t.paused = !1, t.autoPlay())
}, e.prototype.initADA = function () {
var e = this, t = Math.ceil(e.slideCount / e.options.slidesToShow),
o = e.getNavigableIndexes().filter(function (i) {
return i >= 0 && i < e.slideCount
});
e.$slides.add(e.$slideTrack.find(".slick-cloned")).attr({
"aria-hidden": "true",
tabindex: "-1"
}).find("a, input, button, select").attr({tabindex: "-1"}), null !== e.$dots && (e.$slides.not(e.$slideTrack.find(".slick-cloned")).each(function (t) {
var s = o.indexOf(t);
i(this).attr({
role: "tabpanel",
id: "slick-slide" + e.instanceUid + t,
tabindex: -1
}), -1 !== s && i(this).attr({"aria-describedby": "slick-slide-control" + e.instanceUid + s})
}), e.$dots.attr("role", "tablist").find("li").each(function (s) {
var n = o[s];
i(this).attr({role: "presentation"}), i(this).find("button").first().attr({
role: "tab",
id: "slick-slide-control" + e.instanceUid + s,
"aria-controls": "slick-slide" + e.instanceUid + n,
"aria-label": s + 1 + " of " + t,
"aria-selected": null,
tabindex: "-1"
})
}).eq(e.currentSlide).find("button").attr({"aria-selected": "true", tabindex: "0"}).end());
for (var s = e.currentSlide, n = s + e.options.slidesToShow; s < n; s++) e.$slides.eq(s).attr("tabindex", 0);
e.activateADA()
}, e.prototype.initArrowEvents = function () {
var i = this;
!0 === i.options.arrows && i.slideCount > i.options.slidesToShow && (i.$prevArrow.off("click.slick").on("click.slick", {message: "previous"}, i.changeSlide), i.$nextArrow.off("click.slick").on("click.slick", {message: "next"}, i.changeSlide), !0 === i.options.accessibility && (i.$prevArrow.on("keydown.slick", i.keyHandler), i.$nextArrow.on("keydown.slick", i.keyHandler)))
}, e.prototype.initDotEvents = function () {
var e = this;
!0 === e.options.dots && (i("li", e.$dots).on("click.slick", {message: "index"}, e.changeSlide), !0 === e.options.accessibility && e.$dots.on("keydown.slick", e.keyHandler)), !0 === e.options.dots && !0 === e.options.pauseOnDotsHover && i("li", e.$dots).on("mouseenter.slick", i.proxy(e.interrupt, e, !0)).on("mouseleave.slick", i.proxy(e.interrupt, e, !1))
}, e.prototype.initSlideEvents = function () {
var e = this;
e.options.pauseOnHover && (e.$list.on("mouseenter.slick", i.proxy(e.interrupt, e, !0)), e.$list.on("mouseleave.slick", i.proxy(e.interrupt, e, !1)))
}, e.prototype.initializeEvents = function () {
var e = this;
e.initArrowEvents(), e.initDotEvents(), e.initSlideEvents(), e.$list.on("touchstart.slick mousedown.slick", {action: "start"}, e.swipeHandler), e.$list.on("touchmove.slick mousemove.slick", {action: "move"}, e.swipeHandler), e.$list.on("touchend.slick mouseup.slick", {action: "end"}, e.swipeHandler), e.$list.on("touchcancel.slick mouseleave.slick", {action: "end"}, e.swipeHandler), e.$list.on("click.slick", e.clickHandler), i(document).on(e.visibilityChange, i.proxy(e.visibility, e)), !0 === e.options.accessibility && e.$list.on("keydown.slick", e.keyHandler), !0 === e.options.focusOnSelect && i(e.$slideTrack).children().on("click.slick", e.selectHandler), i(window).on("orientationchange.slick.slick-" + e.instanceUid, i.proxy(e.orientationChange, e)), i(window).on("resize.slick.slick-" + e.instanceUid, i.proxy(e.resize, e)), i("[draggable!=true]", e.$slideTrack).on("dragstart", e.preventDefault), i(window).on("load.slick.slick-" + e.instanceUid, e.setPosition), i(e.setPosition)
}, e.prototype.initUI = function () {
var i = this;
!0 === i.options.arrows && i.slideCount > i.options.slidesToShow && (i.$prevArrow.show(), i.$nextArrow.show()), !0 === i.options.dots && i.slideCount > i.options.slidesToShow && i.$dots.show()
}, e.prototype.keyHandler = function (i) {
var e = this;
i.target.tagName.match("TEXTAREA|INPUT|SELECT") || (37 === i.keyCode && !0 === e.options.accessibility ? e.changeSlide({data: {message: !0 === e.options.rtl ? "next" : "previous"}}) : 39 === i.keyCode && !0 === e.options.accessibility && e.changeSlide({data: {message: !0 === e.options.rtl ? "previous" : "next"}}))
}, e.prototype.lazyLoad = function () {
function e(e) {
i("img[data-lazy]", e).each(function () {
var e = i(this), t = i(this).attr("data-lazy"), o = i(this).attr("data-srcset"),
s = i(this).attr("data-sizes") || n.$slider.attr("data-sizes"), r = document.createElement("img");
r.onload = function () {
e.animate({opacity: 0}, 100, function () {
o && (e.attr("srcset", o), s && e.attr("sizes", s)), e.attr("src", t).animate({opacity: 1}, 200, function () {
e.removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading")
}), n.$slider.trigger("lazyLoaded", [n, e, t])
})
}, r.onerror = function () {
e.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"), n.$slider.trigger("lazyLoadError", [n, e, t])
}, r.src = t
})
}
var t, o, s, n = this;
if (!0 === n.options.centerMode ? !0 === n.options.infinite ? s = (o = n.currentSlide + (n.options.slidesToShow / 2 + 1)) + n.options.slidesToShow + 2 : (o = Math.max(0, n.currentSlide - (n.options.slidesToShow / 2 + 1)), s = n.options.slidesToShow / 2 + 1 + 2 + n.currentSlide) : (o = n.options.infinite ? n.options.slidesToShow + n.currentSlide : n.currentSlide, s = Math.ceil(o + n.options.slidesToShow), !0 === n.options.fade && (o > 0 && o--, s <= n.slideCount && s++)), t = n.$slider.find(".slick-slide").slice(o, s), "anticipated" === n.options.lazyLoad) for (var r = o - 1, l = s, d = n.$slider.find(".slick-slide"), a = 0; a < n.options.slidesToScroll; a++) r < 0 && (r = n.slideCount - 1), t = (t = t.add(d.eq(r))).add(d.eq(l)), r--, l++;
e(t), n.slideCount <= n.options.slidesToShow ? e(n.$slider.find(".slick-slide")) : n.currentSlide >= n.slideCount - n.options.slidesToShow ? e(n.$slider.find(".slick-cloned").slice(0, n.options.slidesToShow)) : 0 === n.currentSlide && e(n.$slider.find(".slick-cloned").slice(-1 * n.options.slidesToShow))
}, e.prototype.loadSlider = function () {
var i = this;
i.setPosition(), i.$slideTrack.css({opacity: 1}), i.$slider.removeClass("slick-loading"), i.initUI(), "progressive" === i.options.lazyLoad && i.progressiveLazyLoad()
}, e.prototype.next = e.prototype.slickNext = function () {
this.changeSlide({data: {message: "next"}})
}, e.prototype.orientationChange = function () {
var i = this;
i.checkResponsive(), i.setPosition()
}, e.prototype.pause = e.prototype.slickPause = function () {
var i = this;
i.autoPlayClear(), i.paused = !0
}, e.prototype.play = e.prototype.slickPlay = function () {
var i = this;
i.autoPlay(), i.options.autoplay = !0, i.paused = !1, i.focussed = !1, i.interrupted = !1
}, e.prototype.postSlide = function (e) {
var t = this;
t.unslicked || (t.$slider.trigger("afterChange", [t, e]), t.animating = !1, t.slideCount > t.options.slidesToShow && t.setPosition(), t.swipeLeft = null, t.options.autoplay && t.autoPlay(), !0 === t.options.accessibility && (t.initADA(), t.options.focusOnChange && i(t.$slides.get(t.currentSlide)).attr("tabindex", 0).focus()))
}, e.prototype.prev = e.prototype.slickPrev = function () {
this.changeSlide({data: {message: "previous"}})
}, e.prototype.preventDefault = function (i) {
i.preventDefault()
}, e.prototype.progressiveLazyLoad = function (e) {
e = e || 1;
var t, o, s, n, r, l = this, d = i("img[data-lazy]", l.$slider);
d.length ? (t = d.first(), o = t.attr("data-lazy"), s = t.attr("data-srcset"), n = t.attr("data-sizes") || l.$slider.attr("data-sizes"), (r = document.createElement("img")).onload = function () {
s && (t.attr("srcset", s), n && t.attr("sizes", n)), t.attr("src", o).removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading"), !0 === l.options.adaptiveHeight && l.setPosition(), l.$slider.trigger("lazyLoaded", [l, t, o]), l.progressiveLazyLoad()
}, r.onerror = function () {
e < 3 ? setTimeout(function () {
l.progressiveLazyLoad(e + 1)
}, 500) : (t.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"), l.$slider.trigger("lazyLoadError", [l, t, o]), l.progressiveLazyLoad())
}, r.src = o) : l.$slider.trigger("allImagesLoaded", [l])
}, e.prototype.refresh = function (e) {
var t, o, s = this;
o = s.slideCount - s.options.slidesToShow, !s.options.infinite && s.currentSlide > o && (s.currentSlide = o), s.slideCount <= s.options.slidesToShow && (s.currentSlide = 0), t = s.currentSlide, s.destroy(!0), i.extend(s, s.initials, {currentSlide: t}), s.init(), e || s.changeSlide({
data: {
message: "index",
index: t
}
}, !1)
}, e.prototype.registerBreakpoints = function () {
var e, t, o, s = this, n = s.options.responsive || null;
if ("array" === i.type(n) && n.length) {
s.respondTo = s.options.respondTo || "window";
for (e in n) if (o = s.breakpoints.length - 1, n.hasOwnProperty(e)) {
for (t = n[e].breakpoint; o >= 0;) s.breakpoints[o] && s.breakpoints[o] === t && s.breakpoints.splice(o, 1), o--;
s.breakpoints.push(t), s.breakpointSettings[t] = n[e].settings
}
s.breakpoints.sort(function (i, e) {
return s.options.mobileFirst ? i - e : e - i
})
}
}, e.prototype.reinit = function () {
var e = this;
e.$slides = e.$slideTrack.children(e.options.slide).addClass("slick-slide"), e.slideCount = e.$slides.length, e.currentSlide >= e.slideCount && 0 !== e.currentSlide && (e.currentSlide = e.currentSlide - e.options.slidesToScroll), e.slideCount <= e.options.slidesToShow && (e.currentSlide = 0), e.registerBreakpoints(), e.setProps(), e.setupInfinite(), e.buildArrows(), e.updateArrows(), e.initArrowEvents(), e.buildDots(), e.updateDots(), e.initDotEvents(), e.cleanUpSlideEvents(), e.initSlideEvents(), e.checkResponsive(!1, !0), !0 === e.options.focusOnSelect && i(e.$slideTrack).children().on("click.slick", e.selectHandler), e.setSlideClasses("number" == typeof e.currentSlide ? e.currentSlide : 0), e.setPosition(), e.focusHandler(), e.paused = !e.options.autoplay, e.autoPlay(), e.$slider.trigger("reInit", [e])
}, e.prototype.resize = function () {
var e = this;
i(window).width() !== e.windowWidth && (clearTimeout(e.windowDelay), e.windowDelay = window.setTimeout(function () {
e.windowWidth = i(window).width(), e.checkResponsive(), e.unslicked || e.setPosition()
}, 50))
}, e.prototype.removeSlide = e.prototype.slickRemove = function (i, e, t) {
var o = this;
if (i = "boolean" == typeof i ? !0 === (e = i) ? 0 : o.slideCount - 1 : !0 === e ? --i : i, o.slideCount < 1 || i < 0 || i > o.slideCount - 1) return !1;
o.unload(), !0 === t ? o.$slideTrack.children().remove() : o.$slideTrack.children(this.options.slide).eq(i).remove(), o.$slides = o.$slideTrack.children(this.options.slide), o.$slideTrack.children(this.options.slide).detach(), o.$slideTrack.append(o.$slides), o.$slidesCache = o.$slides, o.reinit()
}, e.prototype.setCSS = function (i) {
var e, t, o = this, s = {};
!0 === o.options.rtl && (i = -i), e = "left" == o.positionProp ? Math.ceil(i) + "px" : "0px", t = "top" == o.positionProp ? Math.ceil(i) + "px" : "0px", s[o.positionProp] = i, !1 === o.transformsEnabled ? o.$slideTrack.css(s) : (s = {}, !1 === o.cssTransitions ? (s[o.animType] = "translate(" + e + ", " + t + ")", o.$slideTrack.css(s)) : (s[o.animType] = "translate3d(" + e + ", " + t + ", 0px)", o.$slideTrack.css(s)))
}, e.prototype.setDimensions = function () {
var i = this;
!1 === i.options.vertical ? !0 === i.options.centerMode && i.$list.css({padding: "0px " + i.options.centerPadding}) : (i.$list.height(i.$slides.first().outerHeight(!0) * i.options.slidesToShow), !0 === i.options.centerMode && i.$list.css({padding: i.options.centerPadding + " 0px"})), i.listWidth = i.$list.width(), i.listHeight = i.$list.height(), !1 === i.options.vertical && !1 === i.options.variableWidth ? (i.slideWidth = Math.ceil(i.listWidth / i.options.slidesToShow), i.$slideTrack.width(Math.ceil(i.slideWidth * i.$slideTrack.children(".slick-slide").length))) : !0 === i.options.variableWidth ? i.$slideTrack.width(5e3 * i.slideCount) : (i.slideWidth = Math.ceil(i.listWidth), i.$slideTrack.height(Math.ceil(i.$slides.first().outerHeight(!0) * i.$slideTrack.children(".slick-slide").length)));
var e = i.$slides.first().outerWidth(!0) - i.$slides.first().width();
!1 === i.options.variableWidth && i.$slideTrack.children(".slick-slide").width(i.slideWidth - e)
}, e.prototype.setFade = function () {
var e, t = this;
t.$slides.each(function (o, s) {
e = t.slideWidth * o * -1, !0 === t.options.rtl ? i(s).css({
position: "relative",
right: e,
top: 0,
zIndex: t.options.zIndex - 2,
opacity: 0
}) : i(s).css({position: "relative", left: e, top: 0, zIndex: t.options.zIndex - 2, opacity: 0})
}), t.$slides.eq(t.currentSlide).css({zIndex: t.options.zIndex - 1, opacity: 1})
}, e.prototype.setHeight = function () {
var i = this;
if (1 === i.options.slidesToShow && !0 === i.options.adaptiveHeight && !1 === i.options.vertical) {
var e = i.$slides.eq(i.currentSlide).outerHeight(!0);
i.$list.css("height", e)
}
}, e.prototype.setOption = e.prototype.slickSetOption = function () {
var e, t, o, s, n, r = this, l = !1;
if ("object" === i.type(arguments[0]) ? (o = arguments[0], l = arguments[1], n = "multiple") : "string" === i.type(arguments[0]) && (o = arguments[0], s = arguments[1], l = arguments[2], "responsive" === arguments[0] && "array" === i.type(arguments[1]) ? n = "responsive" : void 0 !== arguments[1] && (n = "single")), "single" === n) r.options[o] = s; else if ("multiple" === n) i.each(o, function (i, e) {
r.options[i] = e
}); else if ("responsive" === n) for (t in s) if ("array" !== i.type(r.options.responsive)) r.options.responsive = [s[t]]; else {
for (e = r.options.responsive.length - 1; e >= 0;) r.options.responsive[e].breakpoint === s[t].breakpoint && r.options.responsive.splice(e, 1), e--;
r.options.responsive.push(s[t])
}
l && (r.unload(), r.reinit())
}, e.prototype.setPosition = function () {
var i = this;
i.setDimensions(), i.setHeight(), !1 === i.options.fade ? i.setCSS(i.getLeft(i.currentSlide)) : i.setFade(), i.$slider.trigger("setPosition", [i])
}, e.prototype.setProps = function () {
var i = this, e = document.body.style;
i.positionProp = !0 === i.options.vertical ? "top" : "left", "top" === i.positionProp ? i.$slider.addClass("slick-vertical") : i.$slider.removeClass("slick-vertical"), void 0 === e.WebkitTransition && void 0 === e.MozTransition && void 0 === e.msTransition || !0 === i.options.useCSS && (i.cssTransitions = !0), i.options.fade && ("number" == typeof i.options.zIndex ? i.options.zIndex < 3 && (i.options.zIndex = 3) : i.options.zIndex = i.defaults.zIndex), void 0 !== e.OTransform && (i.animType = "OTransform", i.transformType = "-o-transform", i.transitionType = "OTransition", void 0 === e.perspectiveProperty && void 0 === e.webkitPerspective && (i.animType = !1)), void 0 !== e.MozTransform && (i.animType = "MozTransform", i.transformType = "-moz-transform", i.transitionType = "MozTransition", void 0 === e.perspectiveProperty && void 0 === e.MozPerspective && (i.animType = !1)), void 0 !== e.webkitTransform && (i.animType = "webkitTransform", i.transformType = "-webkit-transform", i.transitionType = "webkitTransition", void 0 === e.perspectiveProperty && void 0 === e.webkitPerspective && (i.animType = !1)), void 0 !== e.msTransform && (i.animType = "msTransform", i.transformType = "-ms-transform", i.transitionType = "msTransition", void 0 === e.msTransform && (i.animType = !1)), void 0 !== e.transform && !1 !== i.animType && (i.animType = "transform", i.transformType = "transform", i.transitionType = "transition"), i.transformsEnabled = i.options.useTransform && null !== i.animType && !1 !== i.animType
}, e.prototype.setSlideClasses = function (i) {
var e, t, o, s, n = this;
if (t = n.$slider.find(".slick-slide").removeClass("slick-active slick-center slick-current").attr("aria-hidden", "true"), n.$slides.eq(i).addClass("slick-current"), !0 === n.options.centerMode) {
var r = n.options.slidesToShow % 2 == 0 ? 1 : 0;
e = Math.floor(n.options.slidesToShow / 2), !0 === n.options.infinite && (i >= e && i <= n.slideCount - 1 - e ? n.$slides.slice(i - e + r, i + e + 1).addClass("slick-active").attr("aria-hidden", "false") : (o = n.options.slidesToShow + i, t.slice(o - e + 1 + r, o + e + 2).addClass("slick-active").attr("aria-hidden", "false")), 0 === i ? t.eq(t.length - 1 - n.options.slidesToShow).addClass("slick-center") : i === n.slideCount - 1 && t.eq(n.options.slidesToShow).addClass("slick-center")), n.$slides.eq(i).addClass("slick-center")
} else i >= 0 && i <= n.slideCount - n.options.slidesToShow ? n.$slides.slice(i, i + n.options.slidesToShow).addClass("slick-active").attr("aria-hidden", "false") : t.length <= n.options.slidesToShow ? t.addClass("slick-active").attr("aria-hidden", "false") : (s = n.slideCount % n.options.slidesToShow, o = !0 === n.options.infinite ? n.options.slidesToShow + i : i, n.options.slidesToShow == n.options.slidesToScroll && n.slideCount - i < n.options.slidesToShow ? t.slice(o - (n.options.slidesToShow - s), o + s).addClass("slick-active").attr("aria-hidden", "false") : t.slice(o, o + n.options.slidesToShow).addClass("slick-active").attr("aria-hidden", "false"));
"ondemand" !== n.options.lazyLoad && "anticipated" !== n.options.lazyLoad || n.lazyLoad()
}, e.prototype.setupInfinite = function () {
var e, t, o, s = this;
if (!0 === s.options.fade && (s.options.centerMode = !1), !0 === s.options.infinite && !1 === s.options.fade && (t = null, s.slideCount > s.options.slidesToShow)) {
for (o = !0 === s.options.centerMode ? s.options.slidesToShow + 1 : s.options.slidesToShow, e = s.slideCount; e > s.slideCount - o; e -= 1) t = e - 1, i(s.$slides[t]).clone(!0).attr("id", "").attr("data-slick-index", t - s.slideCount).prependTo(s.$slideTrack).addClass("slick-cloned");
for (e = 0; e < o + s.slideCount; e += 1) t = e, i(s.$slides[t]).clone(!0).attr("id", "").attr("data-slick-index", t + s.slideCount).appendTo(s.$slideTrack).addClass("slick-cloned");
s.$slideTrack.find(".slick-cloned").find("[id]").each(function () {
i(this).attr("id", "")
})
}
}, e.prototype.interrupt = function (i) {
var e = this;
i || e.autoPlay(), e.interrupted = i
}, e.prototype.selectHandler = function (e) {
var t = this, o = i(e.target).is(".slick-slide") ? i(e.target) : i(e.target).parents(".slick-slide"),
s = parseInt(o.attr("data-slick-index"));
s || (s = 0), t.slideCount <= t.options.slidesToShow ? t.slideHandler(s, !1, !0) : t.slideHandler(s)
}, e.prototype.slideHandler = function (i, e, t) {
var o, s, n, r, l, d = null, a = this;
if (e = e || !1, !(!0 === a.animating && !0 === a.options.waitForAnimate || !0 === a.options.fade && a.currentSlide === i)) if (!1 === e && a.asNavFor(i), o = i, d = a.getLeft(o), r = a.getLeft(a.currentSlide), a.currentLeft = null === a.swipeLeft ? r : a.swipeLeft, !1 === a.options.infinite && !1 === a.options.centerMode && (i < 0 || i > a.getDotCount() * a.options.slidesToScroll)) !1 === a.options.fade && (o = a.currentSlide, !0 !== t ? a.animateSlide(r, function () {
a.postSlide(o)
}) : a.postSlide(o)); else if (!1 === a.options.infinite && !0 === a.options.centerMode && (i < 0 || i > a.slideCount - a.options.slidesToScroll)) !1 === a.options.fade && (o = a.currentSlide, !0 !== t ? a.animateSlide(r, function () {
a.postSlide(o)
}) : a.postSlide(o)); else {
if (a.options.autoplay && clearInterval(a.autoPlayTimer), s = o < 0 ? a.slideCount % a.options.slidesToScroll != 0 ? a.slideCount - a.slideCount % a.options.slidesToScroll : a.slideCount + o : o >= a.slideCount ? a.slideCount % a.options.slidesToScroll != 0 ? 0 : o - a.slideCount : o, a.animating = !0, a.$slider.trigger("beforeChange", [a, a.currentSlide, s]), n = a.currentSlide, a.currentSlide = s, a.setSlideClasses(a.currentSlide), a.options.asNavFor && (l = (l = a.getNavTarget()).slick("getSlick")).slideCount <= l.options.slidesToShow && l.setSlideClasses(a.currentSlide), a.updateDots(), a.updateArrows(), !0 === a.options.fade) return !0 !== t ? (a.fadeSlideOut(n), a.fadeSlide(s, function () {
a.postSlide(s)
})) : a.postSlide(s), void a.animateHeight();
!0 !== t ? a.animateSlide(d, function () {
a.postSlide(s)
}) : a.postSlide(s)
}
}, e.prototype.startLoad = function () {
var i = this;
!0 === i.options.arrows && i.slideCount > i.options.slidesToShow && (i.$prevArrow.hide(), i.$nextArrow.hide()), !0 === i.options.dots && i.slideCount > i.options.slidesToShow && i.$dots.hide(), i.$slider.addClass("slick-loading")
}, e.prototype.swipeDirection = function () {
var i, e, t, o, s = this;
return i = s.touchObject.startX - s.touchObject.curX, e = s.touchObject.startY - s.touchObject.curY, t = Math.atan2(e, i), (o = Math.round(180 * t / Math.PI)) < 0 && (o = 360 - Math.abs(o)), o <= 45 && o >= 0 ? !1 === s.options.rtl ? "left" : "right" : o <= 360 && o >= 315 ? !1 === s.options.rtl ? "left" : "right" : o >= 135 && o <= 225 ? !1 === s.options.rtl ? "right" : "left" : !0 === s.options.verticalSwiping ? o >= 35 && o <= 135 ? "down" : "up" : "vertical"
}, e.prototype.swipeEnd = function (i) {
var e, t, o = this;
if (o.dragging = !1, o.swiping = !1, o.scrolling) return o.scrolling = !1, !1;
if (o.interrupted = !1, o.shouldClick = !(o.touchObject.swipeLength > 10), void 0 === o.touchObject.curX) return !1;
if (!0 === o.touchObject.edgeHit && o.$slider.trigger("edge", [o, o.swipeDirection()]), o.touchObject.swipeLength >= o.touchObject.minSwipe) {
switch (t = o.swipeDirection()) {
case"left":
case"down":
e = o.options.swipeToSlide ? o.checkNavigable(o.currentSlide + o.getSlideCount()) : o.currentSlide + o.getSlideCount(), o.currentDirection = 0;
break;
case"right":
case"up":
e = o.options.swipeToSlide ? o.checkNavigable(o.currentSlide - o.getSlideCount()) : o.currentSlide - o.getSlideCount(), o.currentDirection = 1
}
"vertical" != t && (o.slideHandler(e), o.touchObject = {}, o.$slider.trigger("swipe", [o, t]))
} else o.touchObject.startX !== o.touchObject.curX && (o.slideHandler(o.currentSlide), o.touchObject = {})
}, e.prototype.swipeHandler = function (i) {
var e = this;
if (!(!1 === e.options.swipe || "ontouchend" in document && !1 === e.options.swipe || !1 === e.options.draggable && -1 !== i.type.indexOf("mouse"))) switch (e.touchObject.fingerCount = i.originalEvent && void 0 !== i.originalEvent.touches ? i.originalEvent.touches.length : 1, e.touchObject.minSwipe = e.listWidth / e.options.touchThreshold, !0 === e.options.verticalSwiping && (e.touchObject.minSwipe = e.listHeight / e.options.touchThreshold), i.data.action) {
case"start":
e.swipeStart(i);
break;
case"move":
e.swipeMove(i);
break;
case"end":
e.swipeEnd(i)
}
}, e.prototype.swipeMove = function (i) {
var e, t, o, s, n, r, l = this;
return n = void 0 !== i.originalEvent ? i.originalEvent.touches : null, !(!l.dragging || l.scrolling || n && 1 !== n.length) && (e = l.getLeft(l.currentSlide), l.touchObject.curX = void 0 !== n ? n[0].pageX : i.clientX, l.touchObject.curY = void 0 !== n ? n[0].pageY : i.clientY, l.touchObject.swipeLength = Math.round(Math.sqrt(Math.pow(l.touchObject.curX - l.touchObject.startX, 2))), r = Math.round(Math.sqrt(Math.pow(l.touchObject.curY - l.touchObject.startY, 2))), !l.options.verticalSwiping && !l.swiping && r > 4 ? (l.scrolling = !0, !1) : (!0 === l.options.verticalSwiping && (l.touchObject.swipeLength = r), t = l.swipeDirection(), void 0 !== i.originalEvent && l.touchObject.swipeLength > 4 && (l.swiping = !0, i.preventDefault()), s = (!1 === l.options.rtl ? 1 : -1) * (l.touchObject.curX > l.touchObject.startX ? 1 : -1), !0 === l.options.verticalSwiping && (s = l.touchObject.curY > l.touchObject.startY ? 1 : -1), o = l.touchObject.swipeLength, l.touchObject.edgeHit = !1, !1 === l.options.infinite && (0 === l.currentSlide && "right" === t || l.currentSlide >= l.getDotCount() && "left" === t) && (o = l.touchObject.swipeLength * l.options.edgeFriction, l.touchObject.edgeHit = !0), !1 === l.options.vertical ? l.swipeLeft = e + o * s : l.swipeLeft = e + o * (l.$list.height() / l.listWidth) * s, !0 === l.options.verticalSwiping && (l.swipeLeft = e + o * s), !0 !== l.options.fade && !1 !== l.options.touchMove && (!0 === l.animating ? (l.swipeLeft = null, !1) : void l.setCSS(l.swipeLeft))))
}, e.prototype.swipeStart = function (i) {
var e, t = this;
if (t.interrupted = !0, 1 !== t.touchObject.fingerCount || t.slideCount <= t.options.slidesToShow) return t.touchObject = {}, !1;
void 0 !== i.originalEvent && void 0 !== i.originalEvent.touches && (e = i.originalEvent.touches[0]), t.touchObject.startX = t.touchObject.curX = void 0 !== e ? e.pageX : i.clientX, t.touchObject.startY = t.touchObject.curY = void 0 !== e ? e.pageY : i.clientY, t.dragging = !0
}, e.prototype.unfilterSlides = e.prototype.slickUnfilter = function () {
var i = this;
null !== i.$slidesCache && (i.unload(), i.$slideTrack.children(this.options.slide).detach(), i.$slidesCache.appendTo(i.$slideTrack), i.reinit())
}, e.prototype.unload = function () {
var e = this;
i(".slick-cloned", e.$slider).remove(), e.$dots && e.$dots.remove(), e.$prevArrow && e.htmlExpr.test(e.options.prevArrow) && e.$prevArrow.remove(), e.$nextArrow && e.htmlExpr.test(e.options.nextArrow) && e.$nextArrow.remove(), e.$slides.removeClass("slick-slide slick-active slick-visible slick-current").attr("aria-hidden", "true").css("width", "")
}, e.prototype.unslick = function (i) {
var e = this;
e.$slider.trigger("unslick", [e, i]), e.destroy()
}, e.prototype.updateArrows = function () {
var i = this;
Math.floor(i.options.slidesToShow / 2), !0 === i.options.arrows && i.slideCount > i.options.slidesToShow && !i.options.infinite && (i.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false"), i.$nextArrow.removeClass("slick-disabled").attr("aria-disabled", "false"), 0 === i.currentSlide ? (i.$prevArrow.addClass("slick-disabled").attr("aria-disabled", "true"), i.$nextArrow.removeClass("slick-disabled").attr("aria-disabled", "false")) : i.currentSlide >= i.slideCount - i.options.slidesToShow && !1 === i.options.centerMode ? (i.$nextArrow.addClass("slick-disabled").attr("aria-disabled", "true"), i.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false")) : i.currentSlide >= i.slideCount - 1 && !0 === i.options.centerMode && (i.$nextArrow.addClass("slick-disabled").attr("aria-disabled", "true"), i.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false")))
}, e.prototype.updateDots = function () {
var i = this;
null !== i.$dots && (i.$dots.find("li").removeClass("slick-active").end(), i.$dots.find("li").eq(Math.floor(i.currentSlide / i.options.slidesToScroll)).addClass("slick-active"))
}, e.prototype.visibility = function () {
var i = this;
i.options.autoplay && (document[i.hidden] ? i.interrupted = !0 : i.interrupted = !1)
}, i.fn.slick = function () {
var i, t, o = this, s = arguments[0], n = Array.prototype.slice.call(arguments, 1), r = o.length;
for (i = 0; i < r; i++) if ("object" == typeof s || void 0 === s ? o[i].slick = new e(o[i], s) : t = o[i].slick[s].apply(o[i].slick, n), void 0 !== t) return t;
return o
}
});
// Generated by CoffeeScript 1.3.3
(function () {
var e, t;
e = function () {
function e(e, t) {
var n, r;
this.options = {
target: "instafeed",
get: "popular",
resolution: "thumbnail",
sortBy: "none",
links: !0,
mock: !1,
useHttp: !1
};
if (typeof e == "object") for (n in e) r = e[n], this.options[n] = r;
this.context = t != null ? t : this, this.unique = this._genKey()
}
return e.prototype.hasNext = function () {
return typeof this.context.nextUrl == "string" && this.context.nextUrl.length > 0
}, e.prototype.next = function () {
return this.hasNext() ? this.run(this.context.nextUrl) : !1
}, e.prototype.run = function (t) {
var n, r, i;
if (typeof this.options.clientId != "string" && typeof this.options.accessToken != "string") throw new Error("Missing clientId or accessToken.");
if (typeof this.options.accessToken != "string" && typeof this.options.clientId != "string") throw new Error("Missing clientId or accessToken.");
return this.options.before != null && typeof this.options.before == "function" && this.options.before.call(this), typeof document != "undefined" && document !== null && (i = document.createElement("script"), i.id = "instafeed-fetcher", i.src = t || this._buildUrl(), n = document.getElementsByTagName("head"), n[0].appendChild(i), r = "instafeedCache" + this.unique, window[r] = new e(this.options, this), window[r].unique = this.unique), !0
}, e.prototype.parse = function (e) {
var t, n, r, i, s, o, u, a, f, l, c, h, p, d, v, m, g, y, b, w, E, S;
if (typeof e != "object") {
if (this.options.error != null && typeof this.options.error == "function") return this.options.error.call(this, "Invalid JSON data"), !1;
throw new Error("Invalid JSON response")
}
if (e.meta.code !== 200) {
if (this.options.error != null && typeof this.options.error == "function") return this.options.error.call(this, e.meta.error_message), !1;
throw new Error("Error from Instagram: " + e.meta.error_message)
}
if (e.data.length === 0) {
if (this.options.error != null && typeof this.options.error == "function") return this.options.error.call(this, "No images were returned from Instagram"), !1;
throw new Error("No images were returned from Instagram")
}
this.options.success != null && typeof this.options.success == "function" && this.options.success.call(this, e), this.context.nextUrl = "", e.pagination != null && (this.context.nextUrl = e.pagination.next_url);
if (this.options.sortBy !== "none") {
this.options.sortBy === "random" ? d = ["", "random"] : d = this.options.sortBy.split("-"), p = d[0] === "least" ? !0 : !1;
switch (d[1]) {
case"random":
e.data.sort(function () {
return .5 - Math.random()
});
break;
case"recent":
e.data = this._sortBy(e.data, "created_time", p);
break;
case"liked":
e.data = this._sortBy(e.data, "likes.count", p);
break;
case"commented":
e.data = this._sortBy(e.data, "comments.count", p);
break;
default:
throw new Error("Invalid option for sortBy: '" + this.options.sortBy + "'.")
}
}
if (typeof document != "undefined" && document !== null && this.options.mock === !1) {
a = e.data, this.options.limit != null && a.length > this.options.limit && (a = a.slice(0, this.options.limit + 1 || 9e9)), n = document.createDocumentFragment(), this.options.filter != null && typeof this.options.filter == "function" && (a = this._filter(a, this.options.filter));
if (this.options.template != null && typeof this.options.template == "string") {
i = "", o = "", l = "", v = document.createElement("div");
for (m = 0, b = a.length; m < b; m++) s = a[m], u = s.images[this.options.resolution].url, this.options.useHttp || (u = u.replace("http://", "//")), o = this._makeTemplate(this.options.template, {
model: s,
id: s.id,
link: s.link,
image: u,
caption: this._getObjectProperty(s, "caption.text"),
likes: s.likes.count,
comments: s.comments.count,
location: this._getObjectProperty(s, "location.name")
}), i += o;
v.innerHTML = i, S = [].slice.call(v.childNodes);
for (g = 0, w = S.length; g < w; g++) h = S[g], n.appendChild(h)
} else for (y = 0, E = a.length; y < E; y++) s = a[y], f = document.createElement("img"), u = s.images[this.options.resolution].url, this.options.useHttp || (u = u.replace("http://", "//")), f.src = u, this.options.links === !0 ? (t = document.createElement("a"), t.href = s.link, t.appendChild(f), n.appendChild(t)) : n.appendChild(f);
document.getElementById(this.options.target).appendChild(n), r = document.getElementsByTagName("head")[0], r.removeChild(document.getElementById("instafeed-fetcher")), c = "instafeedCache" + this.unique, window[c] = void 0;
try {
delete window[c]
} catch (x) {
}
}
return this.options.after != null && typeof this.options.after == "function" && this.options.after.call(this), !0
}, e.prototype._buildUrl = function () {
var e, t, n;
e = "https://api.instagram.com/v1";
switch (this.options.get) {
case"popular":
t = "media/popular";
break;
case"tagged":
if (typeof this.options.tagName != "string") throw new Error("No tag name specified. Use the 'tagName' option.");
t = "tags/" + this.options.tagName + "/media/recent";
break;
case"location":
if (typeof this.options.locationId != "number") throw new Error("No location specified. Use the 'locationId' option.");
t = "locations/" + this.options.locationId + "/media/recent";
break;
case"user":
if (typeof this.options.userId != "number") throw new Error("No user specified. Use the 'userId' option.");
if (typeof this.options.accessToken != "string") throw new Error("No access token. Use the 'accessToken' option.");
t = "users/" + this.options.userId + "/media/recent";
break;
default:
throw new Error("Invalid option for get: '" + this.options.get + "'.")
}
return n = "" + e + "/" + t, this.options.accessToken != null ? n += "?access_token=" + this.options.accessToken : n += "?client_id=" + this.options.clientId, this.options.limit != null && (n += "&count=" + this.options.limit), n += "&callback=instafeedCache" + this.unique + ".parse", n
}, e.prototype._genKey = function () {
var e;
return e = function () {
return ((1 + Math.random()) * 65536 | 0).toString(16).substring(1)
}, "" + e() + e() + e() + e()
}, e.prototype._makeTemplate = function (e, t) {
var n, r, i, s, o;
r = /(?:\{{2})([\w\[\]\.]+)(?:\}{2})/, n = e;
while (r.test(n)) i = n.match(r)[1], s = (o = this._getObjectProperty(t, i)) != null ? o : "", n = n.replace(r, "" + s);
return n
}, e.prototype._getObjectProperty = function (e, t) {
var n, r;
t = t.replace(/\[(\w+)\]/g, ".$1"), r = t.split(".");
while (r.length) {
n = r.shift();
if (!(e != null && n in e)) return null;
e = e[n]
}
return e
}, e.prototype._sortBy = function (e, t, n) {
var r;
return r = function (e, r) {
var i, s;
return i = this._getObjectProperty(e, t), s = this._getObjectProperty(r, t), n ? i > s ? 1 : -1 : i < s ? 1 : -1
}, e.sort(r.bind(this)), e
}, e.prototype._filter = function (e, t) {
var n, r, i, s, o;
n = [], i = function (e) {
if (t(e)) return n.push(e)
};
for (s = 0, o = e.length; s < o; s++) r = e[s], i(r);
return n
}, e
}(), t = typeof exports != "undefined" && exports !== null ? exports : window, t.Instafeed = e
}).call(this);
/*!
* The Final Countdown for jQuery v2.0.5 (http://hilios.github.io/jQuery.countdown/)
* Copyright (c) 2015 Edson Hilios
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
!function (a) {
"use strict";
"function" == typeof define && define.amd ? define(["jquery"], a) : a(jQuery)
}(function (a) {
"use strict";
function b(a) {
if (a instanceof Date) return a;
if (String(a).match(g)) return String(a).match(/^[0-9]*$/) && (a = Number(a)), String(a).match(/\-/) && (a = String(a).replace(/\-/g, "/")), new Date(a);
throw new Error("Couldn't cast `" + a + "` to a date object.")
}
function c(a) {
var b = a.toString().replace(/([.?*+^$[\]\\(){}|-])/g, "\\$1");
return new RegExp(b)
}
function d(a) {
return function (b) {
var d = b.match(/%(-|!)?[A-Z]{1}(:[^;]+;)?/gi);
if (d) for (var f = 0, g = d.length; g > f; ++f) {
var h = d[f].match(/%(-|!)?([a-zA-Z]{1})(:[^;]+;)?/), j = c(h[0]), k = h[1] || "", l = h[3] || "",
m = null;
h = h[2], i.hasOwnProperty(h) && (m = i[h], m = Number(a[m])), null !== m && ("!" === k && (m = e(l, m)), "" === k && 10 > m && (m = "0" + m.toString()), b = b.replace(j, m.toString()))
}
return b = b.replace(/%%/, "%")
}
}
function e(a, b) {
var c = "s", d = "";
return a && (a = a.replace(/(:|;|\s)/gi, "").split(/\,/), 1 === a.length ? c = a[0] : (d = a[0], c = a[1])), 1 === Math.abs(b) ? d : c
}
var f = [], g = [], h = {precision: 100, elapse: !1};
g.push(/^[0-9]*$/.source), g.push(/([0-9]{1,2}\/){2}[0-9]{4}( [0-9]{1,2}(:[0-9]{2}){2})?/.source), g.push(/[0-9]{4}([\/\-][0-9]{1,2}){2}( [0-9]{1,2}(:[0-9]{2}){2})?/.source), g = new RegExp(g.join("|"));
var i = {Y: "years", m: "months", w: "weeks", d: "days", D: "totalDays", H: "hours", M: "minutes", S: "seconds"},
j = function (b, c, d) {
this.el = b, this.$el = a(b), this.interval = null, this.offset = {}, this.options = a.extend({}, h), this.instanceNumber = f.length, f.push(this), this.$el.data("countdown-instance", this.instanceNumber), d && ("function" == typeof d ? (this.$el.on("update.countdown", d), this.$el.on("stoped.countdown", d), this.$el.on("finish.countdown", d)) : this.options = a.extend({}, h, d)), this.setFinalDate(c), this.start()
};
a.extend(j.prototype, {
start: function () {
null !== this.interval && clearInterval(this.interval);
var a = this;
this.update(), this.interval = setInterval(function () {
a.update.call(a)
}, this.options.precision)
}, stop: function () {
clearInterval(this.interval), this.interval = null, this.dispatchEvent("stoped")
}, toggle: function () {
this.interval ? this.stop() : this.start()
}, pause: function () {
this.stop()
}, resume: function () {
this.start()
}, remove: function () {
this.stop.call(this), f[this.instanceNumber] = null, delete this.$el.data().countdownInstance
}, setFinalDate: function (a) {
this.finalDate = b(a)
}, update: function () {
if (0 === this.$el.closest("html").length) return void this.remove();
var b, c = void 0 !== a._data(this.el, "events"), d = new Date;
b = this.finalDate.getTime() - d.getTime(), b = Math.ceil(b / 1e3), b = !this.options.elapse && 0 > b ? 0 : Math.abs(b), this.totalSecsLeft !== b && c && (this.totalSecsLeft = b, this.elapsed = d >= this.finalDate, this.offset = {
seconds: this.totalSecsLeft % 60,
minutes: Math.floor(this.totalSecsLeft / 60) % 60,
hours: Math.floor(this.totalSecsLeft / 60 / 60) % 24,
days: Math.floor(this.totalSecsLeft / 60 / 60 / 24) % 7,
totalDays: Math.floor(this.totalSecsLeft / 60 / 60 / 24),
weeks: Math.floor(this.totalSecsLeft / 60 / 60 / 24 / 7),
months: Math.floor(this.totalSecsLeft / 60 / 60 / 24 / 30),
years: Math.floor(this.totalSecsLeft / 60 / 60 / 24 / 365)
}, this.options.elapse || 0 !== this.totalSecsLeft ? this.dispatchEvent("update") : (this.stop(), this.dispatchEvent("finish")))
}, dispatchEvent: function (b) {
var c = a.Event(b + ".countdown");
c.finalDate = this.finalDate, c.elapsed = this.elapsed, c.offset = a.extend({}, this.offset), c.strftime = d(this.offset), this.$el.trigger(c)
}
}), a.fn.countdown = function () {
var b = Array.prototype.slice.call(arguments, 0);
return this.each(function () {
var c = a(this).data("countdown-instance");
if (void 0 !== c) {
var d = f[c], e = b[0];
j.prototype.hasOwnProperty(e) ? d[e].apply(d, b.slice(1)) : null === String(e).match(/^[$A-Z_][0-9A-Z_$]*$/i) ? (d.setFinalDate.call(d, e), d.start()) : a.error("Method %s does not exist on jQuery.countdown".replace(/\%s/gi, e))
} else new j(this, b[0], b[1])
})
}
});
/**
* Basic structure: TC_Class is the public class that is returned upon being called
*
* So, if you do
* var tc = $(".timer").TimeCircles();
*
* tc will contain an instance of the public TimeCircles class. It is important to
* note that TimeCircles is not chained in the conventional way, check the
* documentation for more info on how TimeCircles can be chained.
*
* After being called/created, the public TimerCircles class will then- for each element
* within it's collection, either fetch or create an instance of the private class.
* Each function called upon the public class will be forwarded to each instance
* of the private classes within the relevant element collection
**/
(function ($) {
var useWindow = window;
// From https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys
if (!Object.keys) {
Object.keys = (function () {
'use strict';
var hasOwnProperty = Object.prototype.hasOwnProperty,
hasDontEnumBug = !({toString: null}).propertyIsEnumerable('toString'),
dontEnums = [
'toString',
'toLocaleString',
'valueOf',
'hasOwnProperty',
'isPrototypeOf',
'propertyIsEnumerable',
'constructor'
],
dontEnumsLength = dontEnums.length;
return function (obj) {
if (typeof obj !== 'object' && (typeof obj !== 'function' || obj === null)) {
throw new TypeError('Object.keys called on non-object');
}
var result = [], prop, i;
for (prop in obj) {
if (hasOwnProperty.call(obj, prop)) {
result.push(prop);
}
}
if (hasDontEnumBug) {
for (i = 0; i < dontEnumsLength; i++) {
if (hasOwnProperty.call(obj, dontEnums[i])) {
result.push(dontEnums[i]);
}
}
}
return result;
};
}());
}
// Used to disable some features on IE8
var limited_mode = false;
var tick_duration = 200; // in ms
var debug = (location.hash === "#debug");
function debug_log(msg) {
if (debug) {
console.log(msg);
}
}
var allUnits = ["Days", "Hours", "Minutes", "Seconds"];
var nextUnits = {
Seconds: "Minutes",
Minutes: "Hours",
Hours: "Days",
Days: "Years"
};
var secondsIn = {
Seconds: 1,
Minutes: 60,
Hours: 3600,
Days: 86400,
Months: 2678400,
Years: 31536000
};
/**
* Converts hex color code into object containing integer values for the r,g,b use
* This function (hexToRgb) originates from:
* http://stackoverflow.com/questions/5623838/rgb-to-hex-and-hex-to-rgb
* @param {string} hex color code
*/
function hexToRgb(hex) {
// Expand shorthand form (e.g. "03F") to full form (e.g. "0033FF")
var shorthandRegex = /^#?([a-f\d])([a-f\d])([a-f\d])$/i;
hex = hex.replace(shorthandRegex, function (m, r, g, b) {
return r + r + g + g + b + b;
});
var result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
return result ? {
r: parseInt(result[1], 16),
g: parseInt(result[2], 16),
b: parseInt(result[3], 16)
} : null;
}
function isCanvasSupported() {
var elem = document.createElement('canvas');
return !!(elem.getContext && elem.getContext('2d'));
}
/**
* Function s4() and guid() originate from:
* http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript
*/
function s4() {
return Math.floor((1 + Math.random()) * 0x10000)
.toString(16)
.substring(1);
}
/**
* Creates a unique id
* @returns {String}
*/
function guid() {
return s4() + s4() + '-' + s4() + '-' + s4() + '-' +
s4() + '-' + s4() + s4() + s4();
}
/**
* Array.prototype.indexOf fallback for IE8
* @param {Mixed} mixed
* @returns {Number}
*/
if (!Array.prototype.indexOf) {
Array.prototype.indexOf = function (elt /*, from*/) {
var len = this.length >>> 0;
var from = Number(arguments[1]) || 0;
from = (from < 0)
? Math.ceil(from)
: Math.floor(from);
if (from < 0)
from += len;
for (; from < len; from++) {
if (from in this &&
this[from] === elt)
return from;
}
return -1;
};
}
function parse_date(str) {
var match = str.match(/^[0-9]{4}-[0-9]{2}-[0-9]{2}\s[0-9]{1,2}:[0-9]{2}:[0-9]{2}$/);
if (match !== null && match.length > 0) {
var parts = str.split(" ");
var date = parts[0].split("-");
var time = parts[1].split(":");
return new Date(date[0], date[1] - 1, date[2], time[0], time[1], time[2]);
}
// Fallback for different date formats
var d = Date.parse(str);
if (!isNaN(d))
return d;
d = Date.parse(str.replace(/-/g, '/').replace('T', ' '));
if (!isNaN(d))
return d;
// Cant find anything
return new Date();
}
function parse_times(diff, old_diff, total_duration, units, floor) {
var raw_time = {};
var raw_old_time = {};
var time = {};
var pct = {};
var old_pct = {};
var old_time = {};
var greater_unit = null;
for (var i = 0; i < units.length; i++) {
var unit = units[i];
var maxUnits;
if (greater_unit === null) {
maxUnits = total_duration / secondsIn[unit];
} else {
maxUnits = secondsIn[greater_unit] / secondsIn[unit];
}
var curUnits = (diff / secondsIn[unit]);
var oldUnits = (old_diff / secondsIn[unit]);
if (floor) {
if (curUnits > 0) curUnits = Math.floor(curUnits);
else curUnits = Math.ceil(curUnits);
if (oldUnits > 0) oldUnits = Math.floor(oldUnits);
else oldUnits = Math.ceil(oldUnits);
}
if (unit !== "Days") {
curUnits = curUnits % maxUnits;
oldUnits = oldUnits % maxUnits;
}
raw_time[unit] = curUnits;
time[unit] = Math.abs(curUnits);
raw_old_time[unit] = oldUnits;
old_time[unit] = Math.abs(oldUnits);
pct[unit] = Math.abs(curUnits) / maxUnits;
old_pct[unit] = Math.abs(oldUnits) / maxUnits;
greater_unit = unit;
}
return {
raw_time: raw_time,
raw_old_time: raw_old_time,
time: time,
old_time: old_time,
pct: pct,
old_pct: old_pct
};
}
var TC_Instance_List = {};
function updateUsedWindow() {
if (typeof useWindow.TC_Instance_List !== "undefined") {
TC_Instance_List = useWindow.TC_Instance_List;
} else {
useWindow.TC_Instance_List = TC_Instance_List;
}
initializeAnimationFrameHandler(useWindow);
};
function initializeAnimationFrameHandler(w) {
var vendors = ['webkit', 'moz'];
for (var x = 0; x < vendors.length && !w.requestAnimationFrame; ++x) {
w.requestAnimationFrame = w[vendors[x] + 'RequestAnimationFrame'];
w.cancelAnimationFrame = w[vendors[x] + 'CancelAnimationFrame'];
}
if (!w.requestAnimationFrame || !w.cancelAnimationFrame) {
w.requestAnimationFrame = function (callback, element, instance) {
if (typeof instance === "undefined")
instance = {data: {last_frame: 0}};
var currTime = new Date().getTime();
var timeToCall = Math.max(0, 16 - (currTime - instance.data.last_frame));
var id = w.setTimeout(function () {
callback(currTime + timeToCall);
}, timeToCall);
instance.data.last_frame = currTime + timeToCall;
return id;
};
w.cancelAnimationFrame = function (id) {
clearTimeout(id);
};
}
};
var TC_Instance = function (element, options) {
this.element = element;
this.container;
this.listeners = null;
this.data = {
paused: false,
last_frame: 0,
animation_frame: null,
interval_fallback: null,
timer: false,
total_duration: null,
prev_time: null,
drawn_units: [],
text_elements: {
Days: null,
Hours: null,
Minutes: null,
Seconds: null
},
attributes: {
canvas: null,
context: null,
item_size: null,
line_width: null,
radius: null,
outer_radius: null
},
state: {
fading: {
Days: false,
Hours: false,
Minutes: false,
Seconds: false
}
}
};
this.config = null;
this.setOptions(options);
this.initialize();
};
TC_Instance.prototype.clearListeners = function () {
this.listeners = {all: [], visible: []};
};
TC_Instance.prototype.addTime = function (seconds_to_add) {
if (this.data.attributes.ref_date instanceof Date) {
var d = this.data.attributes.ref_date;
d.setSeconds(d.getSeconds() + seconds_to_add);
} else if (!isNaN(this.data.attributes.ref_date)) {
this.data.attributes.ref_date += (seconds_to_add * 1000);
}
};
TC_Instance.prototype.initialize = function (clear_listeners) {
// Initialize drawn units
this.data.drawn_units = [];
for (var i = 0; i < Object.keys(this.config.time).length; i++) {
var unit = Object.keys(this.config.time)[i];
if (this.config.time[unit].show) {
this.data.drawn_units.push(unit);
}
}
// Avoid stacking
$(this.element).children('div.time_circles').remove();
if (typeof clear_listeners === "undefined")
clear_listeners = true;
if (clear_listeners || this.listeners === null) {
this.clearListeners();
}
this.container = $("
");
this.container.addClass('time_circles');
this.container.appendTo(this.element);
// Determine the needed width and height of TimeCircles
var height = this.element.offsetHeight;
var width = this.element.offsetWidth;
if (height === 0)
height = $(this.element).height();
if (width === 0)
width = $(this.element).width();
if (height === 0 && width > 0)
height = width / this.data.drawn_units.length;
else if (width === 0 && height > 0)
width = height * this.data.drawn_units.length;
// Create our canvas and set it to the appropriate size
var canvasElement = document.createElement('canvas');
canvasElement.width = width;
canvasElement.height = height;
// Add canvas elements
this.data.attributes.canvas = $(canvasElement);
this.data.attributes.canvas.appendTo(this.container);
// Check if the browser has browser support
var canvasSupported = isCanvasSupported();
// If the browser doesn't have browser support, check if explorer canvas is loaded
// (A javascript library that adds canvas support to browsers that don't have it)
if (!canvasSupported && typeof G_vmlCanvasManager !== "undefined") {
G_vmlCanvasManager.initElement(canvasElement);
limited_mode = true;
canvasSupported = true;
}
if (canvasSupported) {
this.data.attributes.context = canvasElement.getContext('2d');
}
this.data.attributes.item_size = Math.min(width / this.data.drawn_units.length, height);
this.data.attributes.line_width = this.data.attributes.item_size * this.config.fg_width;
this.data.attributes.radius = ((this.data.attributes.item_size * 0.8) - this.data.attributes.line_width) / 2;
this.data.attributes.outer_radius = this.data.attributes.radius + 0.5 * Math.max(this.data.attributes.line_width, this.data.attributes.line_width * this.config.bg_width);
// Prepare Time Elements
var i = 0;
for (var key in this.data.text_elements) {
if (!this.config.time[key].show)
continue;
var textElement = $("
");
headerElement.text(this.config.time[key].text); // Options
headerElement.css("font-size", Math.round(this.config.text_size * this.data.attributes.item_size));
headerElement.css("line-height", Math.round(this.config.text_size * this.data.attributes.item_size) + "px");
headerElement.appendTo(textElement);
var numberElement = $("");
numberElement.css("font-size", Math.round(3 * this.config.text_size * this.data.attributes.item_size));
numberElement.css("line-height", Math.round(this.config.text_size * this.data.attributes.item_size) + "px");
numberElement.appendTo(textElement);
this.data.text_elements[key] = numberElement;
}
this.start();
if (!this.config.start) {
this.data.paused = true;
}
// Set up interval fallback
var _this = this;
this.data.interval_fallback = useWindow.setInterval(function () {
_this.update.call(_this, true);
}, 100);
};
TC_Instance.prototype.update = function (nodraw) {
if (typeof nodraw === "undefined") {
nodraw = false;
} else if (nodraw && this.data.paused) {
return;
}
if (limited_mode) {
//Per unit clearing doesn't work in IE8 using explorer canvas, so do it in one time. The downside is that radial fade cant be used
this.data.attributes.context.clearRect(0, 0, this.data.attributes.canvas[0].width, this.data.attributes.canvas[0].hright);
}
var diff, old_diff;
var prevDate = this.data.prev_time;
var curDate = new Date();
this.data.prev_time = curDate;
if (prevDate === null)
prevDate = curDate;
// If not counting past zero, and time < 0, then simply draw the zero point once, and call stop
if (!this.config.count_past_zero) {
if (curDate > this.data.attributes.ref_date) {
for (var i = 0; i < this.data.drawn_units.length; i++) {
var key = this.data.drawn_units[i];
// Set the text value
this.data.text_elements[key].text("0");
var x = (i * this.data.attributes.item_size) + (this.data.attributes.item_size / 2);
var y = this.data.attributes.item_size / 2;
var color = this.config.time[key].color;
this.drawArc(x, y, color, 0);
}
this.stop();
return;
}
}
// Compare current time with reference
diff = (this.data.attributes.ref_date - curDate) / 1000;
old_diff = (this.data.attributes.ref_date - prevDate) / 1000;
var floor = this.config.animation !== "smooth";
var visible_times = parse_times(diff, old_diff, this.data.total_duration, this.data.drawn_units, floor);
var all_times = parse_times(diff, old_diff, secondsIn["Years"], allUnits, floor);
var i = 0;
var j = 0;
var lastKey = null;
var cur_shown = this.data.drawn_units.slice();
for (var i in allUnits) {
var key = allUnits[i];
// Notify (all) listeners
if (Math.floor(all_times.raw_time[key]) !== Math.floor(all_times.raw_old_time[key])) {
this.notifyListeners(key, Math.floor(all_times.time[key]), Math.floor(diff), "all");
}
if (cur_shown.indexOf(key) < 0)
continue;
// Notify (visible) listeners
if (Math.floor(visible_times.raw_time[key]) !== Math.floor(visible_times.raw_old_time[key])) {
this.notifyListeners(key, Math.floor(visible_times.time[key]), Math.floor(diff), "visible");
}
if (!nodraw) {
// Set the text value
this.data.text_elements[key].text(Math.floor(Math.abs(visible_times.time[key])));
var x = (j * this.data.attributes.item_size) + (this.data.attributes.item_size / 2);
var y = this.data.attributes.item_size / 2;
var color = this.config.time[key].color;
if (this.config.animation === "smooth") {
if (lastKey !== null && !limited_mode) {
if (Math.floor(visible_times.time[lastKey]) > Math.floor(visible_times.old_time[lastKey])) {
this.radialFade(x, y, color, 1, key);
this.data.state.fading[key] = true;
} else if (Math.floor(visible_times.time[lastKey]) < Math.floor(visible_times.old_time[lastKey])) {
this.radialFade(x, y, color, 0, key);
this.data.state.fading[key] = true;
}
}
if (!this.data.state.fading[key]) {
this.drawArc(x, y, color, visible_times.pct[key]);
}
} else {
this.animateArc(x, y, color, visible_times.pct[key], visible_times.old_pct[key], (new Date()).getTime() + tick_duration);
}
}
lastKey = key;
j++;
}
// Dont request another update if we should be paused
if (this.data.paused || nodraw) {
return;
}
// We need this for our next frame either way
var _this = this;
var update = function () {
_this.update.call(_this);
};
// Either call next update immediately, or in a second
if (this.config.animation === "smooth") {
// Smooth animation, Queue up the next frame
this.data.animation_frame = useWindow.requestAnimationFrame(update, _this.element, _this);
} else {
// Tick animation, Don't queue until very slightly after the next second happens
var delay = (diff % 1) * 1000;
if (delay < 0)
delay = 1000 + delay;
delay += 50;
_this.data.animation_frame = useWindow.setTimeout(function () {
_this.data.animation_frame = useWindow.requestAnimationFrame(update, _this.element, _this);
}, delay);
}
};
TC_Instance.prototype.animateArc = function (x, y, color, target_pct, cur_pct, animation_end) {
if (this.data.attributes.context === null)
return;
var diff = cur_pct - target_pct;
if (Math.abs(diff) > 0.5) {
if (target_pct === 0) {
this.radialFade(x, y, color, 1);
} else {
this.radialFade(x, y, color, 0);
}
} else {
var progress = (tick_duration - (animation_end - (new Date()).getTime())) / tick_duration;
if (progress > 1)
progress = 1;
var pct = (cur_pct * (1 - progress)) + (target_pct * progress);
this.drawArc(x, y, color, pct);
//var show_pct =
if (progress >= 1)
return;
var _this = this;
useWindow.requestAnimationFrame(function () {
_this.animateArc(x, y, color, target_pct, cur_pct, animation_end);
}, this.element);
}
};
TC_Instance.prototype.drawArc = function (x, y, color, pct) {
if (this.data.attributes.context === null)
return;
var clear_radius = Math.max(this.data.attributes.outer_radius, this.data.attributes.item_size / 2);
if (!limited_mode) {
this.data.attributes.context.clearRect(
x - clear_radius,
y - clear_radius,
clear_radius * 2,
clear_radius * 2
);
}
if (this.config.use_background) {
this.data.attributes.context.beginPath();
this.data.attributes.context.arc(x, y, this.data.attributes.radius, 0, 2 * Math.PI, false);
this.data.attributes.context.lineWidth = this.data.attributes.line_width * this.config.bg_width;
// line color
this.data.attributes.context.strokeStyle = this.config.circle_bg_color;
this.data.attributes.context.stroke();
}
// Direction
var startAngle, endAngle, counterClockwise;
var defaultOffset = (-0.5 * Math.PI);
var fullCircle = 2 * Math.PI;
startAngle = defaultOffset + (this.config.start_angle / 360 * fullCircle);
var offset = (2 * pct * Math.PI);
if (this.config.direction === "Both") {
counterClockwise = false;
startAngle -= (offset / 2);
endAngle = startAngle + offset;
} else {
if (this.config.direction === "Clockwise") {
counterClockwise = false;
endAngle = startAngle + offset;
} else {
counterClockwise = true;
endAngle = startAngle - offset;
}
}
this.data.attributes.context.beginPath();
this.data.attributes.context.arc(x, y, this.data.attributes.radius, startAngle, endAngle, counterClockwise);
this.data.attributes.context.lineWidth = this.data.attributes.line_width;
// line color
this.data.attributes.context.strokeStyle = color;
this.data.attributes.context.stroke();
};
TC_Instance.prototype.radialFade = function (x, y, color, from, key) {
// TODO: Make fade_time option
var rgb = hexToRgb(color);
var _this = this; // We have a few inner scopes here that will need access to our instance
var step = 0.2 * ((from === 1) ? -1 : 1);
var i;
for (i = 0; from <= 1 && from >= 0; i++) {
// Create inner scope so our variables are not changed by the time the Timeout triggers
(function () {
var delay = 50 * i;
var rgba = "rgba(" + rgb.r + ", " + rgb.g + ", " + rgb.b + ", " + (Math.round(from * 10) / 10) + ")";
useWindow.setTimeout(function () {
_this.drawArc(x, y, rgba, 1);
}, delay);
}());
from += step;
}
if (typeof key !== undefined) {
useWindow.setTimeout(function () {
_this.data.state.fading[key] = false;
}, 50 * i);
}
};
TC_Instance.prototype.timeLeft = function () {
if (this.data.paused && typeof this.data.timer === "number") {
return this.data.timer;
}
var now = new Date();
return ((this.data.attributes.ref_date - now) / 1000);
};
TC_Instance.prototype.start = function () {
useWindow.cancelAnimationFrame(this.data.animation_frame);
useWindow.clearTimeout(this.data.animation_frame)
// Check if a date was passed in html attribute or jquery data
var attr_data_date = $(this.element).data('date');
if (typeof attr_data_date === "undefined") {
attr_data_date = $(this.element).attr('data-date');
}
if (typeof attr_data_date === "string") {
this.data.attributes.ref_date = parse_date(attr_data_date);
}
// Check if this is an unpause of a timer
else if (typeof this.data.timer === "number") {
if (this.data.paused) {
this.data.attributes.ref_date = (new Date()).getTime() + (this.data.timer * 1000);
}
} else {
// Try to get data-timer
var attr_data_timer = $(this.element).data('timer');
if (typeof attr_data_timer === "undefined") {
attr_data_timer = $(this.element).attr('data-timer');
}
if (typeof attr_data_timer === "string") {
attr_data_timer = parseFloat(attr_data_timer);
}
if (typeof attr_data_timer === "number") {
this.data.timer = attr_data_timer;
this.data.attributes.ref_date = (new Date()).getTime() + (attr_data_timer * 1000);
} else {
// data-timer and data-date were both not set
// use config date
this.data.attributes.ref_date = this.config.ref_date;
}
}
// Start running
this.data.paused = false;
this.update.call(this);
};
TC_Instance.prototype.restart = function () {
this.data.timer = false;
this.start();
};
TC_Instance.prototype.stop = function () {
if (typeof this.data.timer === "number") {
this.data.timer = this.timeLeft(this);
}
// Stop running
this.data.paused = true;
useWindow.cancelAnimationFrame(this.data.animation_frame);
};
TC_Instance.prototype.destroy = function () {
this.clearListeners();
this.stop();
useWindow.clearInterval(this.data.interval_fallback);
this.data.interval_fallback = null;
this.container.remove();
$(this.element).removeAttr('data-tc-id');
$(this.element).removeData('tc-id');
};
TC_Instance.prototype.setOptions = function (options) {
if (this.config === null) {
this.default_options.ref_date = new Date();
this.config = $.extend(true, {}, this.default_options);
}
$.extend(true, this.config, options);
// Use window.top if use_top_frame is true
if (this.config.use_top_frame) {
useWindow = window.top;
} else {
useWindow = window;
}
updateUsedWindow();
this.data.total_duration = this.config.total_duration;
if (typeof this.data.total_duration === "string") {
if (typeof secondsIn[this.data.total_duration] !== "undefined") {
// If set to Years, Months, Days, Hours or Minutes, fetch the secondsIn value for that
this.data.total_duration = secondsIn[this.data.total_duration];
} else if (this.data.total_duration === "Auto") {
// If set to auto, total_duration is the size of 1 unit, of the unit type bigger than the largest shown
for (var i = 0; i < Object.keys(this.config.time).length; i++) {
var unit = Object.keys(this.config.time)[i];
if (this.config.time[unit].show) {
this.data.total_duration = secondsIn[nextUnits[unit]];
break;
}
}
} else {
// If it's a string, but neither of the above, user screwed up.
this.data.total_duration = secondsIn["Years"];
console.error("Valid values for TimeCircles config.total_duration are either numeric, or (string) Years, Months, Days, Hours, Minutes, Auto");
}
}
};
TC_Instance.prototype.addListener = function (f, context, type) {
if (typeof f !== "function")
return;
if (typeof type === "undefined")
type = "visible";
this.listeners[type].push({func: f, scope: context});
};
TC_Instance.prototype.notifyListeners = function (unit, value, total, type) {
for (var i = 0; i < this.listeners[type].length; i++) {
var listener = this.listeners[type][i];
listener.func.apply(listener.scope, [unit, value, total]);
}
};
TC_Instance.prototype.default_options = {
ref_date: new Date(),
start: true,
animation: "smooth",
count_past_zero: true,
circle_bg_color: "#60686F",
use_background: true,
fg_width: 0.1,
bg_width: 1.2,
text_size: 0.07,
total_duration: "Auto",
direction: "Clockwise",
use_top_frame: false,
start_angle: 0,
time: {
Days: {
show: true,
text: "Days",
color: "#FC6"
},
Hours: {
show: true,
text: "Hours",
color: "#9CF"
},
Minutes: {
show: true,
text: "Minutes",
color: "#BFB"
},
Seconds: {
show: true,
text: "Seconds",
color: "#F99"
}
}
};
// Time circle class
var TC_Class = function (elements, options) {
this.elements = elements;
this.options = options;
this.foreach();
};
TC_Class.prototype.getInstance = function (element) {
var instance;
var cur_id = $(element).data("tc-id");
if (typeof cur_id === "undefined") {
cur_id = guid();
$(element).attr("data-tc-id", cur_id);
}
if (typeof TC_Instance_List[cur_id] === "undefined") {
var options = this.options;
var element_options = $(element).data('options');
if (typeof element_options === "string") {
element_options = JSON.parse(element_options);
}
if (typeof element_options === "object") {
options = $.extend(true, {}, this.options, element_options);
}
instance = new TC_Instance(element, options);
TC_Instance_List[cur_id] = instance;
} else {
instance = TC_Instance_List[cur_id];
if (typeof this.options !== "undefined") {
instance.setOptions(this.options);
}
}
return instance;
};
TC_Class.prototype.addTime = function (seconds_to_add) {
this.foreach(function (instance) {
instance.addTime(seconds_to_add);
});
};
TC_Class.prototype.foreach = function (callback) {
var _this = this;
this.elements.each(function () {
var instance = _this.getInstance(this);
if (typeof callback === "function") {
callback(instance);
}
});
return this;
};
TC_Class.prototype.start = function () {
this.foreach(function (instance) {
instance.start();
});
return this;
};
TC_Class.prototype.stop = function () {
this.foreach(function (instance) {
instance.stop();
});
return this;
};
TC_Class.prototype.restart = function () {
this.foreach(function (instance) {
instance.restart();
});
return this;
};
TC_Class.prototype.rebuild = function () {
this.foreach(function (instance) {
instance.initialize(false);
});
return this;
};
TC_Class.prototype.getTime = function () {
return this.getInstance(this.elements[0]).timeLeft();
};
TC_Class.prototype.addListener = function (f, type) {
if (typeof type === "undefined")
type = "visible";
var _this = this;
this.foreach(function (instance) {
instance.addListener(f, _this.elements, type);
});
return this;
};
TC_Class.prototype.destroy = function () {
this.foreach(function (instance) {
instance.destroy();
});
return this;
};
TC_Class.prototype.end = function () {
return this.elements;
};
$.fn.TimeCircles = function (options) {
return new TC_Class(this, options);
};
}(jQuery));
(function ($) {
$.fn.TreeSixtyImageRotate = function (options) {
let base = this;
let settings = $.extend({
// These are the defaults.
totalFrames: 36, // Total number of image you have
endFrame: 36, // end frame for the auto spin animation
currentFrame: 0, // This the start frame for auto spin
speed: 100, // speed of auto rotate option
dragSpeed: 6, // speed of rotation when dragging elements
progress: ".spinner", // selector to show the loading progress
extension: ".jpg", // extension for the images
imgPrefix: "",
navigation: true, // display navigation
spinner: true, // disable spinner for loading
imagesFolder: "images/", // path to folder with images
smallWidth: 400, // smaller width for images
smallHeight: 400, // smaller height for images
largeWidth: 800, // larger width for images
largeHeight: 800, // larger height for images
imagePlaceholderClass: "images-placeholder", // class for images placeholder
imgList: "threesixty-images-rotate" // selector for image list
}, options);
/**
* @method initTreeSixty
* The function starts creation process of TreeSixtyImageRotate
*/
base.initTreeSixty = function () {
base.css({
"height": settings.smallHeight,
"width": settings.smallWidth,
"position": "relative",
"margin": "auto"
});
if (settings.spinner) {
base.spinner("start");
}
if (settings.navigation) {
base.createNavigation();
}
let changeSlide = false, previousSlide = false, nextNext = false, xAxis, nextXAxis;
base.find(".images-list").on("mousedown touchstart", function (e) {
e.preventDefault();
if (e.type === "mousedown") {
xAxis = e.pageX;
} else {
xAxis = e.originalEvent.touches[0].pageX;
}
changeSlide = true;
}).on("mousemove touchmove", function (e) {
if (changeSlide) {
if (e.type === "mousemove") {
nextXAxis = e.pageX;
} else {
nextXAxis = e.originalEvent.touches[0].pageX;
}
if (nextXAxis > xAxis + settings.dragSpeed) {
previousSlide = true;
xAxis = nextXAxis;
base.previous();
} else if (nextXAxis < xAxis - settings.dragSpeed) {
nextNext = true;
xAxis = nextXAxis;
base.next();
}
}
}).on("mouseleave mouseup touchend", function (e) {
changeSlide = false;
});
if (settings.spinner) {
base.spinner("stop");
}
};
/**
* @method createNavigation
* Creates navigation menu for TreeSixtyImageRotate display
*/
base.createNavigation = function () {
let navigationBarWrapper, navigationBar, next, previous, playStop;
navigationBarWrapper = $("").attr("class", "navigation-bar-wrapper");
navigationBar = $("").attr("class", "navigation-bar");
next = $("").attr({
"class": "navigation-bar-next"
});
previous = $("").attr({
"class": "navigation-bar-previous"
});
playStop = $("").attr({
"class": "navigation-bar-play"
});
navigationBar.append(previous);
navigationBar.append(playStop);
navigationBar.append(next);
navigationBarWrapper.append(navigationBar);
base.append(navigationBarWrapper);
let nextInterval;
next.on("mousedown touchstart", function (e) {
e.preventDefault();
nextInterval = setInterval(function () {
base.next()
}, settings.speed)
}).on("mouseleave mouseup touchend", function () {
clearInterval(nextInterval);
});
let previousInterval;
previous.on("mousedown touchstart", function (e) {
e.preventDefault();
previousInterval = setInterval(function () {
base.previous()
}, settings.speed)
}).on("mouseleave mouseup touchend", function () {
clearInterval(previousInterval);
});
let play = false, playStopInterval;
playStop.on("mousedown touchstart", function (e) {
e.preventDefault();
if (!play) {
base.find('.navigation-bar-play').addClass('navigation-bar-stop');
play = true;
playStopInterval = setInterval(function () {
base.next()
}, settings.speed)
} else {
base.find('.navigation-bar-play').removeClass('navigation-bar-stop');
play = false;
clearInterval(playStopInterval)
}
});
};
/**
* @method spinner
* Creates loader to be display during content creation
* Also can hide loader depending on status
*/
base.spinner = function (status) {
let spinner;
spinner = $("").attr({
"class": "loading-spinner"
});
base.append(spinner);
if (status === "start") {
let winWidth = $(window).width();
if (winWidth > 991) {
base.find('.loading-spinner').css({
"height": settings.smallHeight,
"width": settings.smallWidth,
})
} else {
base.find('.loading-spinner').css({
"max-height": settings.largeHeight,
"max-width": settings.largeWidth,
"height": winWidth,
"width": winWidth,
});
}
} else if (status === "stop") {
base.find('.loading-spinner').css({
"display": "none"
});
} else {
console.log("Invalid status for spinner");
}
};
/**
* @method next
* Hide current image and next image
*/
base.next = function () {
let currentSlide = base.find(".active");
let imgPositionClass = currentSlide.attr("class").split(/\s+/)[1];
let imgPossition = parseInt(imgPositionClass.substring(6));
imgPossition--;
if (imgPossition < 0) {
imgPossition = settings.totalFrames;
}
let nextImgClass = "image-" + imgPossition;
base.find("." + nextImgClass).addClass("active");
currentSlide.removeClass("active");
};
/**
* @method previous
* Hide current image and previous image
*/
base.previous = function () {
let currentSlide = base.find(".active");
let imgPositionClass = currentSlide.attr("class").split(/\s+/)[1];
let imgPossition = parseInt(imgPositionClass.substring(6));
imgPossition++;
if (imgPossition > settings.totalFrames) {
imgPossition = 0;
}
let nextImgClass = "image-" + imgPossition;
base.find("." + nextImgClass).addClass("active");
currentSlide.removeClass("active");
};
/**
* @method togleFullScreen
* Activates and dissactivates full screen state
*/
base.togleFullScreen = function () {
if (!$(document)[0].fullscreenElement &&
!$(document)[0].mozFullScreenElement && !$(document)[0].webkitFullscreenElement && !$(document)[0].msFullscreenElement) { // current working methods
if ($(this)[0].requestFullscreen) {
$(this)[0].requestFullscreen();
} else if ($(this)[0].msRequestFullscreen) {
$(this)[0].msRequestFullscreen();
} else if ($(this)[0].mozRequestFullScreen) {
$(this)[0].mozRequestFullScreen();
} else if ($(this)[0].webkitRequestFullscreen) {
$(this)[0].webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT);
}
} else {
if ($(document)[0].exitFullscreen) {
$(document)[0].exitFullscreen();
} else if ($(document)[0].msExitFullscreen) {
$(document)[0].msExitFullscreen();
} else if ($(document)[0].mozCancelFullScreen) {
$(document)[0].mozCancelFullScreen();
} else if ($(document)[0].webkitExitFullscreen) {
$(document)[0].webkitExitFullscreen();
}
}
};
base.on('webkitfullscreenchange mozfullscreenchange fullscreenchange', function (e) {
base.resize();
});
$(window).resize(function (e) {
let winWidth = $(window).width();
if (winWidth > 991) {
base.css({
"height": settings.smallHeight,
"width": settings.smallWidth,
})
} else {
base.css({
"max-height": settings.largeHeight,
"max-width": settings.largeWidth,
"height": winWidth,
"width": winWidth,
});
}
});
$(document).ready(function (e) {
let winWidth = $(window).width();
if (winWidth > 991) {
base.css({
"height": settings.smallHeight,
"width": settings.smallWidth,
})
} else {
base.css({
"max-height": settings.largeHeight,
"max-width": settings.largeWidth,
"height": winWidth,
"width": winWidth,
});
}
});
return base;
};
})
(jQuery);
/*! sly 1.6.0 - 17th Jul 2015 | https://github.com/darsain/sly */
!function (a, b, c) {
"use strict";
function d(b, p, q) {
function K(c) {
var d = 0, e = Gb.length;
if (yb.old = a.extend({}, yb), wb = tb ? 0 : ub[rb.horizontal ? "width" : "height"](), Bb = zb[rb.horizontal ? "width" : "height"](), xb = tb ? b : vb[rb.horizontal ? "outerWidth" : "outerHeight"](), Gb.length = 0, yb.start = 0, yb.end = H(xb - wb, 0), Rb) {
d = Ib.length, Hb = vb.children(rb.itemSelector), Ib.length = 0;
var f, g = j(vb, rb.horizontal ? "paddingLeft" : "paddingTop"),
h = j(vb, rb.horizontal ? "paddingRight" : "paddingBottom"),
i = "border-box" === a(Hb).css("boxSizing"), l = "none" !== Hb.css("float"), m = 0,
n = Hb.length - 1;
xb = 0, Hb.each(function (b, c) {
var d = a(c), e = c.getBoundingClientRect(),
i = G(rb.horizontal ? e.width || e.right - e.left : e.height || e.bottom - e.top),
k = j(d, rb.horizontal ? "marginLeft" : "marginTop"),
o = j(d, rb.horizontal ? "marginRight" : "marginBottom"), p = i + k + o, q = !k || !o, r = {};
r.el = c, r.size = q ? i : p, r.half = r.size / 2, r.start = xb + (q ? k : 0), r.center = r.start - G(wb / 2 - r.size / 2), r.end = r.start - wb + r.size, b || (xb += g), xb += p, rb.horizontal || l || o && k && b > 0 && (xb -= I(k, o)), b === n && (r.end += h, xb += h, m = q ? o : 0), Ib.push(r), f = r
}), vb[0].style[rb.horizontal ? "width" : "height"] = (i ? xb : xb - g - h) + "px", xb -= m, Ib.length ? (yb.start = Ib[0][Pb ? "center" : "start"], yb.end = Pb ? f.center : xb > wb ? f.end : yb.start) : yb.start = yb.end = 0
}
if (yb.center = G(yb.end / 2 + yb.start / 2), V(), Ab.length && Bb > 0 && (rb.dynamicHandle ? (Cb = yb.start === yb.end ? Bb : G(Bb * wb / xb), Cb = k(Cb, rb.minHandleSize, Bb), Ab[0].style[rb.horizontal ? "width" : "height"] = Cb + "px") : Cb = Ab[rb.horizontal ? "outerWidth" : "outerHeight"](), Db.end = Bb - Cb, ec || N()), !tb && wb > 0) {
var o = yb.start, p = "";
if (Rb) a.each(Ib, function (a, b) {
Pb ? Gb.push(b.center) : b.start + b.size > o && o <= yb.end && (o = b.start, Gb.push(o), o += wb, o > yb.end && o < yb.end + wb && Gb.push(yb.end))
}); else for (; o - wb < yb.end;) Gb.push(o), o += wb;
if (Eb[0] && e !== Gb.length) {
for (var q = 0; q < Gb.length; q++) p += rb.pageBuilder.call(sb, q);
Fb = Eb.html(p).children(), Fb.eq(Jb.activePage).addClass(rb.activeClass)
}
}
if (Jb.slideeSize = xb, Jb.frameSize = wb, Jb.sbSize = Bb, Jb.handleSize = Cb, Rb) {
c && null != rb.startAt && (T(rb.startAt), sb[Qb ? "toCenter" : "toStart"](rb.startAt));
var r = Ib[Jb.activeItem];
L(Qb && r ? r.center : k(yb.dest, yb.start, yb.end))
} else c ? null != rb.startAt && L(rb.startAt, 1) : L(k(yb.dest, yb.start, yb.end));
ob("load")
}
function L(a, b, c) {
if (Rb && cc.released && !c) {
var d = U(a), e = a > yb.start && a < yb.end;
Qb ? (e && (a = Ib[d.centerItem].center), Pb && rb.activateMiddle && T(d.centerItem)) : e && (a = Ib[d.firstItem].start)
}
cc.init && cc.slidee && rb.elasticBounds ? a > yb.end ? a = yb.end + (a - yb.end) / 6 : a < yb.start && (a = yb.start + (a - yb.start) / 6) : a = k(a, yb.start, yb.end), ac.start = +new Date, ac.time = 0, ac.from = yb.cur, ac.to = a, ac.delta = a - yb.cur, ac.tweesing = cc.tweese || cc.init && !cc.slidee, ac.immediate = !ac.tweesing && (b || cc.init && cc.slidee || !rb.speed), cc.tweese = 0, a !== yb.dest && (yb.dest = a, ob("change"), ec || M()), Z(), V(), W(), O()
}
function M() {
if (sb.initialized) {
if (!ec) return ec = t(M), void (cc.released && ob("moveStart"));
ac.immediate ? yb.cur = ac.to : ac.tweesing ? (ac.tweeseDelta = ac.to - yb.cur, D(ac.tweeseDelta) < .1 ? yb.cur = ac.to : yb.cur += ac.tweeseDelta * (cc.released ? rb.swingSpeed : rb.syncSpeed)) : (ac.time = I(+new Date - ac.start, rb.speed), yb.cur = ac.from + ac.delta * a.easing[rb.easing](ac.time / rb.speed, ac.time, 0, 1, rb.speed)), ac.to === yb.cur ? (yb.cur = ac.to, cc.tweese = ec = 0) : ec = t(M), ob("move"), tb || (m ? vb[0].style[m] = n + (rb.horizontal ? "translateX" : "translateY") + "(" + -yb.cur + "px)" : vb[0].style[rb.horizontal ? "left" : "top"] = -G(yb.cur) + "px"), !ec && cc.released && ob("moveEnd"), N()
}
}
function N() {
Ab.length && (Db.cur = yb.start === yb.end ? 0 : ((cc.init && !cc.slidee ? yb.dest : yb.cur) - yb.start) / (yb.end - yb.start) * Db.end, Db.cur = k(G(Db.cur), Db.start, Db.end), _b.hPos !== Db.cur && (_b.hPos = Db.cur, m ? Ab[0].style[m] = n + (rb.horizontal ? "translateX" : "translateY") + "(" + Db.cur + "px)" : Ab[0].style[rb.horizontal ? "left" : "top"] = Db.cur + "px"))
}
function O() {
Fb[0] && _b.page !== Jb.activePage && (_b.page = Jb.activePage, Fb.removeClass(rb.activeClass).eq(Jb.activePage).addClass(rb.activeClass), ob("activePage", _b.page))
}
function P() {
bc.speed && yb.cur !== (bc.speed > 0 ? yb.end : yb.start) || sb.stop(), hc = cc.init ? t(P) : 0, bc.now = +new Date, bc.pos = yb.cur + (bc.now - bc.lastTime) / 1e3 * bc.speed, L(cc.init ? bc.pos : G(bc.pos)), cc.init || yb.cur !== yb.dest || ob("moveEnd"), bc.lastTime = bc.now
}
function Q(a, b, d) {
if ("boolean" === e(b) && (d = b, b = c), b === c) L(yb[a], d); else {
if (Qb && "center" !== a) return;
var f = sb.getPos(b);
f && L(f[a], d, !Qb)
}
}
function R(a) {
return null != a ? i(a) ? a >= 0 && a < Ib.length ? a : -1 : Hb.index(a) : -1
}
function S(a) {
return R(i(a) && 0 > a ? a + Ib.length : a)
}
function T(a, b) {
var c = R(a);
return !Rb || 0 > c ? !1 : ((_b.active !== c || b) && (Hb.eq(Jb.activeItem).removeClass(rb.activeClass), Hb.eq(c).addClass(rb.activeClass), _b.active = Jb.activeItem = c, W(), ob("active", c)), c)
}
function U(a) {
a = k(i(a) ? a : yb.dest, yb.start, yb.end);
var b = {}, c = Pb ? 0 : wb / 2;
if (!tb) for (var d = 0, e = Gb.length; e > d; d++) {
if (a >= yb.end || d === Gb.length - 1) {
b.activePage = Gb.length - 1;
break
}
if (a <= Gb[d] + c) {
b.activePage = d;
break
}
}
if (Rb) {
for (var f = !1, g = !1, h = !1, j = 0, l = Ib.length; l > j; j++) if (f === !1 && a <= Ib[j].start + Ib[j].half && (f = j), h === !1 && a <= Ib[j].center + Ib[j].half && (h = j), j === l - 1 || a <= Ib[j].end + Ib[j].half) {
g = j;
break
}
b.firstItem = i(f) ? f : 0, b.centerItem = i(h) ? h : b.firstItem, b.lastItem = i(g) ? g : b.centerItem
}
return b
}
function V(b) {
a.extend(Jb, U(b))
}
function W() {
var a = yb.dest <= yb.start, b = yb.dest >= yb.end, c = (a ? 1 : 0) | (b ? 2 : 0);
if (_b.slideePosState !== c && (_b.slideePosState = c, Yb.is("button,input") && Yb.prop("disabled", a), Zb.is("button,input") && Zb.prop("disabled", b), Yb.add(Vb)[a ? "addClass" : "removeClass"](rb.disabledClass), Zb.add(Ub)[b ? "addClass" : "removeClass"](rb.disabledClass)), _b.fwdbwdState !== c && cc.released && (_b.fwdbwdState = c, Vb.is("button,input") && Vb.prop("disabled", a), Ub.is("button,input") && Ub.prop("disabled", b)), Rb && null != Jb.activeItem) {
var d = 0 === Jb.activeItem, e = Jb.activeItem >= Ib.length - 1, f = (d ? 1 : 0) | (e ? 2 : 0);
_b.itemsButtonState !== f && (_b.itemsButtonState = f, Wb.is("button,input") && Wb.prop("disabled", d), Xb.is("button,input") && Xb.prop("disabled", e), Wb[d ? "addClass" : "removeClass"](rb.disabledClass), Xb[e ? "addClass" : "removeClass"](rb.disabledClass))
}
}
function X(a, b, c) {
if (a = S(a), b = S(b), a > -1 && b > -1 && a !== b && (!c || b !== a - 1) && (c || b !== a + 1)) {
Hb.eq(a)[c ? "insertAfter" : "insertBefore"](Ib[b].el);
var d = b > a ? a : c ? b : b - 1, e = a > b ? a : c ? b + 1 : b, f = a > b;
null != Jb.activeItem && (a === Jb.activeItem ? _b.active = Jb.activeItem = c ? f ? b + 1 : b : f ? b : b - 1 : Jb.activeItem > d && Jb.activeItem < e && (_b.active = Jb.activeItem += f ? 1 : -1)), K()
}
}
function Y(a, b) {
for (var c = 0, d = $b[a].length; d > c; c++) if ($b[a][c] === b) return c;
return -1
}
function Z() {
cc.released && !sb.isPaused && sb.resume()
}
function $(a) {
return G(k(a, Db.start, Db.end) / Db.end * (yb.end - yb.start)) + yb.start
}
function _() {
cc.history[0] = cc.history[1], cc.history[1] = cc.history[2], cc.history[2] = cc.history[3], cc.history[3] = cc.delta
}
function ab(a) {
cc.released = 0, cc.source = a, cc.slidee = "slidee" === a
}
function bb(b) {
var c = "touchstart" === b.type, d = b.data.source, e = "slidee" === d;
cc.init || !c && eb(b.target) || ("handle" !== d || rb.dragHandle && Db.start !== Db.end) && (!e || (c ? rb.touchDragging : rb.mouseDragging && b.which < 2)) && (c || f(b), ab(d), cc.init = 0, cc.$source = a(b.target), cc.touch = c, cc.pointer = c ? b.originalEvent.touches[0] : b, cc.initX = cc.pointer.pageX, cc.initY = cc.pointer.pageY, cc.initPos = e ? yb.cur : Db.cur, cc.start = +new Date, cc.time = 0, cc.path = 0, cc.delta = 0, cc.locked = 0, cc.history = [0, 0, 0, 0], cc.pathToLock = e ? c ? 30 : 10 : 0, u.on(c ? x : w, cb), sb.pause(1), (e ? vb : Ab).addClass(rb.draggedClass), ob("moveStart"), e && (fc = setInterval(_, 10)))
}
function cb(a) {
if (cc.released = "mouseup" === a.type || "touchend" === a.type, cc.pointer = cc.touch ? a.originalEvent[cc.released ? "changedTouches" : "touches"][0] : a, cc.pathX = cc.pointer.pageX - cc.initX, cc.pathY = cc.pointer.pageY - cc.initY, cc.path = E(F(cc.pathX, 2) + F(cc.pathY, 2)), cc.delta = rb.horizontal ? cc.pathX : cc.pathY, cc.released || !(cc.path < 1)) {
if (!cc.init) {
if (cc.path < rb.dragThreshold) return cc.released ? db() : c;
if (!(rb.horizontal ? D(cc.pathX) > D(cc.pathY) : D(cc.pathX) < D(cc.pathY))) return db();
cc.init = 1
}
f(a), !cc.locked && cc.path > cc.pathToLock && cc.slidee && (cc.locked = 1, cc.$source.on(z, g)), cc.released && (db(), rb.releaseSwing && cc.slidee && (cc.swing = (cc.delta - cc.history[0]) / 40 * 300, cc.delta += cc.swing, cc.tweese = D(cc.swing) > 10)), L(cc.slidee ? G(cc.initPos - cc.delta) : $(cc.initPos + cc.delta))
}
}
function db() {
clearInterval(fc), cc.released = !0, u.off(cc.touch ? x : w, cb), (cc.slidee ? vb : Ab).removeClass(rb.draggedClass), setTimeout(function () {
cc.$source.off(z, g)
}), yb.cur === yb.dest && cc.init && ob("moveEnd"), sb.resume(1), cc.init = 0
}
function eb(b) {
return ~a.inArray(b.nodeName, B) || a(b).is(rb.interactive)
}
function fb() {
sb.stop(), u.off("mouseup", fb)
}
function gb(a) {
switch (f(a), this) {
case Ub[0]:
case Vb[0]:
sb.moveBy(Ub.is(this) ? rb.moveBy : -rb.moveBy), u.on("mouseup", fb);
break;
case Wb[0]:
sb.prev();
break;
case Xb[0]:
sb.next();
break;
case Yb[0]:
sb.prevPage();
break;
case Zb[0]:
sb.nextPage()
}
}
function hb(a) {
return dc.curDelta = (rb.horizontal ? a.deltaY || a.deltaX : a.deltaY) || -a.wheelDelta, dc.curDelta /= 1 === a.deltaMode ? 3 : 100, Rb ? (o = +new Date, dc.last < o - dc.resetTime && (dc.delta = 0), dc.last = o, dc.delta += dc.curDelta, D(dc.delta) < 1 ? dc.finalDelta = 0 : (dc.finalDelta = G(dc.delta / 1), dc.delta %= 1), dc.finalDelta) : dc.curDelta
}
function ib(a) {
a.originalEvent[r] = sb;
var b = +new Date;
if (J + rb.scrollHijack > b && Sb[0] !== document && Sb[0] !== window) return void (J = b);
if (rb.scrollBy && yb.start !== yb.end) {
var c = hb(a.originalEvent);
(rb.scrollTrap || c > 0 && yb.dest < yb.end || 0 > c && yb.dest > yb.start) && f(a, 1), sb.slideBy(rb.scrollBy * c)
}
}
function jb(a) {
rb.clickBar && a.target === zb[0] && (f(a), L($((rb.horizontal ? a.pageX - zb.offset().left : a.pageY - zb.offset().top) - Cb / 2)))
}
function kb(a) {
if (rb.keyboardNavBy) switch (a.which) {
case rb.horizontal ? 37 : 38:
f(a), sb["pages" === rb.keyboardNavBy ? "prevPage" : "prev"]();
break;
case rb.horizontal ? 39 : 40:
f(a), sb["pages" === rb.keyboardNavBy ? "nextPage" : "next"]()
}
}
function lb(a) {
return eb(this) ? void (a.originalEvent[r + "ignore"] = !0) : void (this.parentNode !== vb[0] || a.originalEvent[r + "ignore"] || sb.activate(this))
}
function mb() {
this.parentNode === Eb[0] && sb.activatePage(Fb.index(this))
}
function nb(a) {
rb.pauseOnHover && sb["mouseenter" === a.type ? "pause" : "resume"](2)
}
function ob(a, b) {
if ($b[a]) {
for (qb = $b[a].length, C.length = 0, pb = 0; qb > pb; pb++) C.push($b[a][pb]);
for (pb = 0; qb > pb; pb++) C[pb].call(sb, a, b)
}
}
var pb, qb, rb = a.extend({}, d.defaults, p), sb = this, tb = i(b), ub = a(b),
vb = rb.slidee ? a(rb.slidee).eq(0) : ub.children().eq(0), wb = 0, xb = 0,
yb = {start: 0, center: 0, end: 0, cur: 0, dest: 0}, zb = a(rb.scrollBar).eq(0), Ab = zb.children().eq(0),
Bb = 0, Cb = 0, Db = {start: 0, end: 0, cur: 0}, Eb = a(rb.pagesBar), Fb = 0, Gb = [], Hb = 0, Ib = [],
Jb = {firstItem: 0, lastItem: 0, centerItem: 0, activeItem: null, activePage: 0}, Kb = new l(ub[0]),
Lb = new l(vb[0]), Mb = new l(zb[0]), Nb = new l(Ab[0]), Ob = "basic" === rb.itemNav,
Pb = "forceCentered" === rb.itemNav, Qb = "centered" === rb.itemNav || Pb, Rb = !tb && (Ob || Qb || Pb),
Sb = rb.scrollSource ? a(rb.scrollSource) : ub, Tb = rb.dragSource ? a(rb.dragSource) : ub,
Ub = a(rb.forward), Vb = a(rb.backward), Wb = a(rb.prev), Xb = a(rb.next), Yb = a(rb.prevPage),
Zb = a(rb.nextPage), $b = {}, _b = {}, ac = {}, bc = {}, cc = {released: 1},
dc = {last: 0, delta: 0, resetTime: 200}, ec = 0, fc = 0, gc = 0, hc = 0;
tb || (b = ub[0]), sb.initialized = 0, sb.frame = b, sb.slidee = vb[0], sb.pos = yb, sb.rel = Jb, sb.items = Ib, sb.pages = Gb, sb.isPaused = 0, sb.options = rb, sb.dragging = cc, sb.reload = function () {
K()
}, sb.getPos = function (a) {
if (Rb) {
var b = R(a);
return -1 !== b ? Ib[b] : !1
}
var c = vb.find(a).eq(0);
if (c[0]) {
var d = rb.horizontal ? c.offset().left - vb.offset().left : c.offset().top - vb.offset().top,
e = c[rb.horizontal ? "outerWidth" : "outerHeight"]();
return {start: d, center: d - wb / 2 + e / 2, end: d - wb + e, size: e}
}
return !1
}, sb.moveBy = function (a) {
bc.speed = a, !cc.init && bc.speed && yb.cur !== (bc.speed > 0 ? yb.end : yb.start) && (bc.lastTime = +new Date, bc.startPos = yb.cur, ab("button"), cc.init = 1, ob("moveStart"), s(hc), P())
}, sb.stop = function () {
"button" === cc.source && (cc.init = 0, cc.released = 1)
}, sb.prev = function () {
sb.activate(null == Jb.activeItem ? 0 : Jb.activeItem - 1)
}, sb.next = function () {
sb.activate(null == Jb.activeItem ? 0 : Jb.activeItem + 1)
}, sb.prevPage = function () {
sb.activatePage(Jb.activePage - 1)
}, sb.nextPage = function () {
sb.activatePage(Jb.activePage + 1)
}, sb.slideBy = function (a, b) {
a && (Rb ? sb[Qb ? "toCenter" : "toStart"](k((Qb ? Jb.centerItem : Jb.firstItem) + rb.scrollBy * a, 0, Ib.length)) : L(yb.dest + a, b))
}, sb.slideTo = function (a, b) {
L(a, b)
}, sb.toStart = function (a, b) {
Q("start", a, b)
}, sb.toEnd = function (a, b) {
Q("end", a, b)
}, sb.toCenter = function (a, b) {
Q("center", a, b)
}, sb.getIndex = R, sb.activate = function (a, b) {
var c = T(a);
rb.smart && c !== !1 && (Qb ? sb.toCenter(c, b) : c >= Jb.lastItem ? sb.toStart(c, b) : c <= Jb.firstItem ? sb.toEnd(c, b) : Z())
}, sb.activatePage = function (a, b) {
i(a) && L(Gb[k(a, 0, Gb.length - 1)], b)
}, sb.resume = function (a) {
rb.cycleBy && rb.cycleInterval && ("items" !== rb.cycleBy || Ib[0] && null != Jb.activeItem) && !(a < sb.isPaused) && (sb.isPaused = 0, gc ? gc = clearTimeout(gc) : ob("resume"), gc = setTimeout(function () {
switch (ob("cycle"), rb.cycleBy) {
case"items":
sb.activate(Jb.activeItem >= Ib.length - 1 ? 0 : Jb.activeItem + 1);
break;
case"pages":
sb.activatePage(Jb.activePage >= Gb.length - 1 ? 0 : Jb.activePage + 1)
}
}, rb.cycleInterval))
}, sb.pause = function (a) {
a < sb.isPaused || (sb.isPaused = a || 100, gc && (gc = clearTimeout(gc), ob("pause")))
}, sb.toggle = function () {
sb[gc ? "pause" : "resume"]()
}, sb.set = function (b, c) {
a.isPlainObject(b) ? a.extend(rb, b) : rb.hasOwnProperty(b) && (rb[b] = c)
}, sb.add = function (b, c) {
var d = a(b);
Rb ? (null == c || !Ib[0] || c >= Ib.length ? d.appendTo(vb) : Ib.length && d.insertBefore(Ib[c].el), null != Jb.activeItem && c <= Jb.activeItem && (_b.active = Jb.activeItem += d.length)) : vb.append(d), K()
}, sb.remove = function (b) {
if (Rb) {
var c = S(b);
if (c > -1) {
Hb.eq(c).remove();
var d = c === Jb.activeItem;
null != Jb.activeItem && c < Jb.activeItem && (_b.active = --Jb.activeItem), K(), d && (_b.active = null, sb.activate(Jb.activeItem))
}
} else a(b).remove(), K()
}, sb.moveAfter = function (a, b) {
X(a, b, 1)
}, sb.moveBefore = function (a, b) {
X(a, b)
}, sb.on = function (a, b) {
if ("object" === e(a)) for (var c in a) a.hasOwnProperty(c) && sb.on(c, a[c]); else if ("function" === e(b)) for (var d = a.split(" "), f = 0, g = d.length; g > f; f++) $b[d[f]] = $b[d[f]] || [], -1 === Y(d[f], b) && $b[d[f]].push(b); else if ("array" === e(b)) for (var h = 0, i = b.length; i > h; h++) sb.on(a, b[h])
}, sb.one = function (a, b) {
function c() {
b.apply(sb, arguments), sb.off(a, c)
}
sb.on(a, c)
}, sb.off = function (a, b) {
if (b instanceof Array) for (var c = 0, d = b.length; d > c; c++) sb.off(a, b[c]); else for (var e = a.split(" "), f = 0, g = e.length; g > f; f++) if ($b[e[f]] = $b[e[f]] || [], null == b) $b[e[f]].length = 0; else {
var h = Y(e[f], b);
-1 !== h && $b[e[f]].splice(h, 1)
}
}, sb.destroy = function () {
return Sb.add(Ab).add(zb).add(Eb).add(Ub).add(Vb).add(Wb).add(Xb).add(Yb).add(Zb).off("." + r), u.off("keydown", kb), Wb.add(Xb).add(Yb).add(Zb).removeClass(rb.disabledClass), Hb && null != Jb.activeItem && Hb.eq(Jb.activeItem).removeClass(rb.activeClass), Eb.empty(), tb || (ub.off("." + r), Kb.restore(), Lb.restore(), Mb.restore(), Nb.restore(), a.removeData(b, r)), Ib.length = Gb.length = 0, _b = {}, sb.initialized = 0, sb
}, sb.init = function () {
if (!sb.initialized) {
sb.on(q);
var a = ["overflow", "position"],
b = ["position", "webkitTransform", "msTransform", "transform", "left", "top", "width", "height"];
Kb.save.apply(Kb, a), Mb.save.apply(Mb, a), Lb.save.apply(Lb, b), Nb.save.apply(Nb, b);
var c = Ab;
return tb || (c = c.add(vb), ub.css("overflow", "hidden"), m || "static" !== ub.css("position") || ub.css("position", "relative")), m ? n && c.css(m, n) : ("static" === zb.css("position") && zb.css("position", "relative"), c.css({position: "absolute"})), rb.forward && Ub.on(A, gb), rb.backward && Vb.on(A, gb), rb.prev && Wb.on(z, gb), rb.next && Xb.on(z, gb), rb.prevPage && Yb.on(z, gb), rb.nextPage && Zb.on(z, gb), Sb.on(y, ib), zb[0] && zb.on(z, jb), Rb && rb.activateOn && ub.on(rb.activateOn + "." + r, "*", lb), Eb[0] && rb.activatePageOn && Eb.on(rb.activatePageOn + "." + r, "*", mb), Tb.on(v, {source: "slidee"}, bb), Ab && Ab.on(v, {source: "handle"}, bb), u.on("keydown", kb), tb || (ub.on("mouseenter." + r + " mouseleave." + r, nb), ub.on("scroll." + r, h)), sb.initialized = 1, K(!0), rb.cycleBy && !tb && sb[rb.startPaused ? "pause" : "resume"](), sb
}
}
}
function e(a) {
return null == a ? String(a) : "object" == typeof a || "function" == typeof a ? Object.prototype.toString.call(a).match(/\s([a-z]+)/i)[1].toLowerCase() || "object" : typeof a
}
function f(a, b) {
a.preventDefault(), b && a.stopPropagation()
}
function g(b) {
f(b, 1), a(this).off(b.type, g)
}
function h() {
this.scrollLeft = 0, this.scrollTop = 0
}
function i(a) {
return !isNaN(parseFloat(a)) && isFinite(a)
}
function j(a, b) {
return 0 | G(String(a.css(b)).replace(/[^\-0-9.]/g, ""))
}
function k(a, b, c) {
return b > a ? b : a > c ? c : a
}
function l(a) {
var b = {};
return b.style = {}, b.save = function () {
if (a && a.nodeType) {
for (var c = 0; c < arguments.length; c++) b.style[arguments[c]] = a.style[arguments[c]];
return b
}
}, b.restore = function () {
if (a && a.nodeType) {
for (var c in b.style) b.style.hasOwnProperty(c) && (a.style[c] = b.style[c]);
return b
}
}, b
}
var m, n, o, p = "sly", q = "Sly", r = p, s = b.cancelAnimationFrame || b.cancelRequestAnimationFrame,
t = b.requestAnimationFrame, u = a(document), v = "touchstart." + r + " mousedown." + r,
w = "mousemove." + r + " mouseup." + r, x = "touchmove." + r + " touchend." + r,
y = (document.implementation.hasFeature("Event.wheel", "3.0") ? "wheel." : "mousewheel.") + r, z = "click." + r,
A = "mousedown." + r, B = ["INPUT", "SELECT", "BUTTON", "TEXTAREA"], C = [], D = Math.abs, E = Math.sqrt,
F = Math.pow, G = Math.round, H = Math.max, I = Math.min, J = 0;
u.on(y, function (a) {
var b = a.originalEvent[r], c = +new Date;
(!b || b.options.scrollHijack < c - J) && (J = c)
}), function (a) {
function b(a) {
var b = (new Date).getTime(), d = Math.max(0, 16 - (b - c)), e = setTimeout(a, d);
return c = b, e
}
t = a.requestAnimationFrame || a.webkitRequestAnimationFrame || b;
var c = (new Date).getTime(), d = a.cancelAnimationFrame || a.webkitCancelAnimationFrame || a.clearTimeout;
s = function (b) {
d.call(a, b)
}
}(window), function () {
function a(a) {
for (var d = 0, e = b.length; e > d; d++) {
var f = b[d] ? b[d] + a.charAt(0).toUpperCase() + a.slice(1) : a;
if (null != c.style[f]) return f
}
}
var b = ["", "Webkit", "Moz", "ms", "O"], c = document.createElement("div");
m = a("transform"), n = a("perspective") ? "translateZ(0) " : ""
}(), b[q] = d, a.fn[p] = function (b, c) {
var f, g;
return a.isPlainObject(b) || (("string" === e(b) || b === !1) && (f = b === !1 ? "destroy" : b, g = Array.prototype.slice.call(arguments, 1)), b = {}), this.each(function (e, h) {
var i = a.data(h, r);
i || f ? i && f && i[f] && i[f].apply(i, g) : i = a.data(h, r, new d(h, b, c).init())
})
}, d.defaults = {
slidee: null,
horizontal: !1,
itemNav: null,
itemSelector: null,
smart: !1,
activateOn: null,
activateMiddle: !1,
scrollSource: null,
scrollBy: 0,
scrollHijack: 300,
scrollTrap: !1,
dragSource: null,
mouseDragging: !1,
touchDragging: !1,
releaseSwing: !1,
swingSpeed: .2,
elasticBounds: !1,
dragThreshold: 3,
interactive: null,
scrollBar: null,
dragHandle: !1,
dynamicHandle: !1,
minHandleSize: 50,
clickBar: !1,
syncSpeed: .5,
pagesBar: null,
activatePageOn: null,
pageBuilder: function (a) {
return "
" + (a + 1) + "
"
},
forward: null,
backward: null,
prev: null,
next: null,
prevPage: null,
nextPage: null,
cycleBy: null,
cycleInterval: 5e3,
pauseOnHover: !1,
startPaused: !1,
moveBy: 300,
speed: 0,
easing: "swing",
startAt: null,
keyboardNavBy: null,
draggedClass: "dragged",
activeClass: "active",
disabledClass: "disabled"
}
}(jQuery, window);
/*! lazysizes - v4.1.8 */
!function (a, b) {
var c = b(a, a.document);
a.lazySizes = c, "object" == typeof module && module.exports && (module.exports = c)
}(window, function (a, b) {
"use strict";
if (b.getElementsByClassName) {
var c, d, e = b.documentElement, f = a.Date, g = a.HTMLPictureElement, h = "addEventListener",
i = "getAttribute", j = a[h], k = a.setTimeout, l = a.requestAnimationFrame || k, m = a.requestIdleCallback,
n = /^picture$/i, o = ["load", "error", "lazyincluded", "_lazyloaded"], p = {}, q = Array.prototype.forEach,
r = function (a, b) {
return p[b] || (p[b] = new RegExp("(\\s|^)" + b + "(\\s|$)")), p[b].test(a[i]("class") || "") && p[b]
}, s = function (a, b) {
r(a, b) || a.setAttribute("class", (a[i]("class") || "").trim() + " " + b)
}, t = function (a, b) {
var c;
(c = r(a, b)) && a.setAttribute("class", (a[i]("class") || "").replace(c, " "))
}, u = function (a, b, c) {
var d = c ? h : "removeEventListener";
c && u(a, b), o.forEach(function (c) {
a[d](c, b)
})
}, v = function (a, d, e, f, g) {
var h = b.createEvent("Event");
return e || (e = {}), e.instance = c, h.initEvent(d, !f, !g), h.detail = e, a.dispatchEvent(h), h
}, w = function (b, c) {
var e;
!g && (e = a.picturefill || d.pf) ? (c && c.src && !b[i]("srcset") && b.setAttribute("srcset", c.src), e({
reevaluate: !0,
elements: [b]
})) : c && c.src && (b.src = c.src)
}, x = function (a, b) {
return (getComputedStyle(a, null) || {})[b]
}, y = function (a, b, c) {
for (c = c || a.offsetWidth; c < d.minSize && b && !a._lazysizesWidth;) c = b.offsetWidth, b = b.parentNode;
return c
}, z = function () {
var a, c, d = [], e = [], f = d, g = function () {
var b = f;
for (f = d.length ? e : d, a = !0, c = !1; b.length;) b.shift()();
a = !1
}, h = function (d, e) {
a && !e ? d.apply(this, arguments) : (f.push(d), c || (c = !0, (b.hidden ? k : l)(g)))
};
return h._lsFlush = g, h
}(), A = function (a, b) {
return b ? function () {
z(a)
} : function () {
var b = this, c = arguments;
z(function () {
a.apply(b, c)
})
}
}, B = function (a) {
var b, c = 0, e = d.throttleDelay, g = d.ricTimeout, h = function () {
b = !1, c = f.now(), a()
}, i = m && g > 49 ? function () {
m(h, {timeout: g}), g !== d.ricTimeout && (g = d.ricTimeout)
} : A(function () {
k(h)
}, !0);
return function (a) {
var d;
(a = !0 === a) && (g = 33), b || (b = !0, d = e - (f.now() - c), d < 0 && (d = 0), a || d < 9 ? i() : k(i, d))
}
}, C = function (a) {
var b, c, d = 99, e = function () {
b = null, a()
}, g = function () {
var a = f.now() - c;
a < d ? k(g, d - a) : (m || e)(e)
};
return function () {
c = f.now(), b || (b = k(g, d))
}
};
!function () {
var b, c = {
lazyClass: "lazyload",
loadedClass: "lazyloaded",
loadingClass: "lazyloading",
preloadClass: "lazypreload",
errorClass: "lazyerror",
autosizesClass: "lazyautosizes",
srcAttr: "data-src",
srcsetAttr: "data-srcset",
sizesAttr: "data-sizes",
minSize: 40,
customMedia: {},
init: !0,
expFactor: 1.5,
hFac: .8,
loadMode: 2,
loadHidden: !0,
ricTimeout: 0,
throttleDelay: 125
};
d = a.lazySizesConfig || a.lazysizesConfig || {};
for (b in c) b in d || (d[b] = c[b]);
a.lazySizesConfig = d, k(function () {
d.init && F()
})
}();
var D = function () {
var g, l, m, o, p, y, D, F, G, H, I, J, K = /^img$/i, L = /^iframe$/i,
M = "onscroll" in a && !/(gle|ing)bot/.test(navigator.userAgent), N = 0, O = 0, P = 0, Q = -1,
R = function (a) {
P-- , (!a || P < 0 || !a.target) && (P = 0)
}, S = function (a) {
return null == J && (J = "hidden" == x(b.body, "visibility")), J || "hidden" != x(a.parentNode, "visibility") && "hidden" != x(a, "visibility")
}, T = function (a, c) {
var d, f = a, g = S(a);
for (F -= c, I += c, G -= c, H += c; g && (f = f.offsetParent) && f != b.body && f != e;) (g = (x(f, "opacity") || 1) > 0) && "visible" != x(f, "overflow") && (d = f.getBoundingClientRect(), g = H > d.left && G < d.right && I > d.top - 1 && F < d.bottom + 1);
return g
}, U = function () {
var a, f, h, j, k, m, n, p, q, r, s, t, u = c.elements;
if ((o = d.loadMode) && P < 8 && (a = u.length)) {
for (f = 0, Q++; f < a; f++) if (u[f] && !u[f]._lazyRace) if (!M || c.prematureUnveil && c.prematureUnveil(u[f])) aa(u[f]); else if ((p = u[f][i]("data-expand")) && (m = 1 * p) || (m = O), r || (r = !d.expand || d.expand < 1 ? e.clientHeight > 500 && e.clientWidth > 500 ? 500 : 370 : d.expand, c._defEx = r, s = r * d.expFactor, t = d.hFac, J = null, O < s && P < 1 && Q > 2 && o > 2 && !b.hidden ? (O = s, Q = 0) : O = o > 1 && Q > 1 && P < 6 ? r : N), q !== m && (y = innerWidth + m * t, D = innerHeight + m, n = -1 * m, q = m), h = u[f].getBoundingClientRect(), (I = h.bottom) >= n && (F = h.top) <= D && (H = h.right) >= n * t && (G = h.left) <= y && (I || H || G || F) && (d.loadHidden || S(u[f])) && (l && P < 3 && !p && (o < 3 || Q < 4) || T(u[f], m))) {
if (aa(u[f]), k = !0, P > 9) break
} else !k && l && !j && P < 4 && Q < 4 && o > 2 && (g[0] || d.preloadAfterLoad) && (g[0] || !p && (I || H || G || F || "auto" != u[f][i](d.sizesAttr))) && (j = g[0] || u[f]);
j && !k && aa(j)
}
}, V = B(U), W = function (a) {
var b = a.target;
if (b._lazyCache) return void delete b._lazyCache;
R(a), s(b, d.loadedClass), t(b, d.loadingClass), u(b, Y), v(b, "lazyloaded")
}, X = A(W), Y = function (a) {
X({target: a.target})
}, Z = function (a, b) {
try {
a.contentWindow.location.replace(b)
} catch (c) {
a.src = b
}
}, $ = function (a) {
var b, c = a[i](d.srcsetAttr);
(b = d.customMedia[a[i]("data-media") || a[i]("media")]) && a.setAttribute("media", b), c && a.setAttribute("srcset", c)
}, _ = A(function (a, b, c, e, f) {
var g, h, j, l, o, p;
(o = v(a, "lazybeforeunveil", b)).defaultPrevented || (e && (c ? s(a, d.autosizesClass) : a.setAttribute("sizes", e)), h = a[i](d.srcsetAttr), g = a[i](d.srcAttr), f && (j = a.parentNode, l = j && n.test(j.nodeName || "")), p = b.firesLoad || "src" in a && (h || g || l), o = {target: a}, s(a, d.loadingClass), p && (clearTimeout(m), m = k(R, 2500), u(a, Y, !0)), l && q.call(j.getElementsByTagName("source"), $), h ? a.setAttribute("srcset", h) : g && !l && (L.test(a.nodeName) ? Z(a, g) : a.src = g), f && (h || l) && w(a, {src: g})), a._lazyRace && delete a._lazyRace, t(a, d.lazyClass), z(function () {
var b = a.complete && a.naturalWidth > 1;
p && !b || (b && s(a, "ls-is-cached"), W(o), a._lazyCache = !0, k(function () {
"_lazyCache" in a && delete a._lazyCache
}, 9)), "lazy" == a.loading && P--
}, !0)
}), aa = function (a) {
if (!a._lazyRace) {
var b, c = K.test(a.nodeName), e = c && (a[i](d.sizesAttr) || a[i]("sizes")), f = "auto" == e;
(!f && l || !c || !a[i]("src") && !a.srcset || a.complete || r(a, d.errorClass) || !r(a, d.lazyClass)) && (b = v(a, "lazyunveilread").detail, f && E.updateElem(a, !0, a.offsetWidth), a._lazyRace = !0, P++ , _(a, b, f, e, c))
}
}, ba = C(function () {
d.loadMode = 3, V()
}), ca = function () {
3 == d.loadMode && (d.loadMode = 2), ba()
}, da = function () {
if (!l) {
if (f.now() - p < 999) return void k(da, 999);
l = !0, d.loadMode = 3, V(), j("scroll", ca, !0)
}
};
return {
_: function () {
p = f.now(), c.elements = b.getElementsByClassName(d.lazyClass), g = b.getElementsByClassName(d.lazyClass + " " + d.preloadClass), j("scroll", V, !0), j("resize", V, !0), a.MutationObserver ? new MutationObserver(V).observe(e, {
childList: !0,
subtree: !0,
attributes: !0
}) : (e[h]("DOMNodeInserted", V, !0), e[h]("DOMAttrModified", V, !0), setInterval(V, 999)), j("hashchange", V, !0), ["focus", "mouseover", "click", "load", "transitionend", "animationend", "webkitAnimationEnd"].forEach(function (a) {
b[h](a, V, !0)
}), /d$|^c/.test(b.readyState) ? da() : (j("load", da), b[h]("DOMContentLoaded", V), k(da, 2e4)), c.elements.length ? (U(), z._lsFlush()) : V()
}, checkElems: V, unveil: aa, _aLSL: ca
}
}(), E = function () {
var a, c = A(function (a, b, c, d) {
var e, f, g;
if (a._lazysizesWidth = d, d += "px", a.setAttribute("sizes", d), n.test(b.nodeName || "")) for (e = b.getElementsByTagName("source"), f = 0, g = e.length; f < g; f++) e[f].setAttribute("sizes", d);
c.detail.dataAttr || w(a, c.detail)
}), e = function (a, b, d) {
var e, f = a.parentNode;
f && (d = y(a, f, d), e = v(a, "lazybeforesizes", {
width: d,
dataAttr: !!b
}), e.defaultPrevented || (d = e.detail.width) && d !== a._lazysizesWidth && c(a, f, e, d))
}, f = function () {
var b, c = a.length;
if (c) for (b = 0; b < c; b++) e(a[b])
}, g = C(f);
return {
_: function () {
a = b.getElementsByClassName(d.autosizesClass), j("resize", g)
}, checkElems: g, updateElem: e
}
}(), F = function () {
F.i || (F.i = !0, E._(), D._())
};
return c = {cfg: d, autoSizer: E, loader: D, init: F, uP: w, aC: s, rC: t, hC: r, fire: v, gW: y, rAF: z}
}
});
/*! ls.rias.min.ks - v4.1.8 */
!function (a, b) {
var c = function () {
b(a.lazySizes), a.removeEventListener("lazyunveilread", c, !0)
};
b = b.bind(null, a, a.document), "object" == typeof module && module.exports ? b(require("lazysizes")) : a.lazySizes ? c() : a.addEventListener("lazyunveilread", c, !0)
}(window, function (a, b, c) {
"use strict";
function d(b, c) {
var d, e, f, g, h = a.getComputedStyle(b);
e = b.parentNode, g = {isPicture: !(!e || !m.test(e.nodeName || ""))}, f = function (a, c) {
var d = b.getAttribute("data-" + a);
if (!d) {
var e = h.getPropertyValue("--ls-" + a);
e && (d = e.trim())
}
if (d) {
if ("true" == d) d = !0; else if ("false" == d) d = !1; else if (l.test(d)) d = parseFloat(d); else if ("function" == typeof j[a]) d = j[a](b, d); else if (q.test(d)) try {
d = JSON.parse(d)
} catch (a) {
}
g[a] = d
} else a in j && "function" != typeof j[a] ? g[a] = j[a] : c && "function" == typeof j[a] && (g[a] = j[a](b, d))
};
for (d in j) f(d);
return c.replace(p, function (a, b) {
b in g || f(b, !0)
}), g
}
function e(a, b) {
var c = [], d = function (a, c) {
return k[typeof b[c]] ? b[c] : a
};
return c.srcset = [], b.absUrl && (s.setAttribute("href", a), a = s.href), a = ((b.prefix || "") + a + (b.postfix || "")).replace(p, d), b.widths.forEach(function (d) {
var e = b.widthmap[d] || d, f = b.aspectratio || b.ratio, g = !b.aspectratio && j.traditionalRatio,
h = {u: a.replace(n, e).replace(o, f ? g ? Math.round(d * f) : Math.round(d / f) : ""), w: d};
c.push(h), c.srcset.push(h.c = h.u + " " + d + "w")
}), c
}
function f(a, c, d) {
var f = 0, g = 0, h = d;
if (a) {
if ("container" === c.ratio) {
for (f = h.scrollWidth, g = h.scrollHeight; !(f && g || h === b);) h = h.parentNode, f = h.scrollWidth, g = h.scrollHeight;
f && g && (c.ratio = g / f)
}
a = e(a, c), a.isPicture = c.isPicture, u && "IMG" == d.nodeName.toUpperCase() ? d.removeAttribute(i.srcsetAttr) : d.setAttribute(i.srcsetAttr, a.srcset.join(", ")), Object.defineProperty(d, "_lazyrias", {
value: a,
writable: !0
})
}
}
function g(a, b) {
var e = d(a, b);
return j.modifyOptions.call(a, {target: a, details: e, detail: e}), c.fire(a, "lazyriasmodifyoptions", e), e
}
function h(a) {
return a.getAttribute(a.getAttribute("data-srcattr") || j.srcAttr) || a.getAttribute(i.srcsetAttr) || a.getAttribute(i.srcAttr) || a.getAttribute("data-pfsrcset") || ""
}
var i, j, k = {string: 1, number: 1}, l = /^\-*\+*\d+\.*\d*$/, m = /^picture$/i, n = /\s*\{\s*width\s*\}\s*/i,
o = /\s*\{\s*height\s*\}\s*/i, p = /\s*\{\s*([a-z0-9]+)\s*\}\s*/gi, q = /^\[.*\]|\{.*\}$/,
r = /^(?:auto|\d+(px)?)$/, s = b.createElement("a"), t = b.createElement("img"),
u = "srcset" in t && !("sizes" in t), v = !!a.HTMLPictureElement && !u;
!function () {
var b, d = function () {
}, e = {
prefix: "",
postfix: "",
srcAttr: "data-src",
absUrl: !1,
modifyOptions: d,
widthmap: {},
ratio: !1,
traditionalRatio: !1,
aspectratio: !1
};
i = c && c.cfg || a.lazySizesConfig, i || (i = {}, a.lazySizesConfig = i), i.supportsType || (i.supportsType = function (a) {
return !a
}), i.rias || (i.rias = {}), "widths" in (j = i.rias) || (j.widths = [], function (a) {
for (var b, c = 0; !b || b < 3e3;) c += 5, c > 30 && (c += 1), b = 36 * c, a.push(b)
}(j.widths));
for (b in e) b in j || (j[b] = e[b])
}(), addEventListener("lazybeforesizes", function (a) {
if (a.detail.instance == c) {
var b, d, e, k, l, m, o, p, q, s, t, u, x;
if (b = a.target, a.detail.dataAttr && !a.defaultPrevented && !j.disabled && (q = b.getAttribute(i.sizesAttr) || b.getAttribute("sizes")) && r.test(q)) {
if (d = h(b), e = g(b, d), t = n.test(e.prefix) || n.test(e.postfix), e.isPicture && (k = b.parentNode)) for (l = k.getElementsByTagName("source"), m = 0, o = l.length; m < o; m++) (t || n.test(p = h(l[m]))) && (f(p, e, l[m]), u = !0);
t || n.test(d) ? (f(d, e, b), u = !0) : u && (x = [], x.srcset = [], x.isPicture = !0, Object.defineProperty(b, "_lazyrias", {
value: x,
writable: !0
})), u && (v ? b.removeAttribute(i.srcAttr) : "auto" != q && (s = {width: parseInt(q, 10)}, w({
target: b,
detail: s
})))
}
}
}, !0);
var w = function () {
var d = function (a, b) {
return a.w - b.w
}, e = function (a) {
var b, c, d = a.length, e = a[d - 1], f = 0;
for (f; f < d; f++) if (e = a[f], e.d = e.w / a.w, e.d >= a.d) {
!e.cached && (b = a[f - 1]) && b.d > a.d - .13 * Math.pow(a.d, 2.2) && (c = Math.pow(b.d - .6, 1.6), b.cached && (b.d += .15 * c), b.d + (e.d - a.d) * c > a.d && (e = b));
break
}
return e
}, f = function (a, b) {
var d;
return !a._lazyrias && c.pWS && (d = c.pWS(a.getAttribute(i.srcsetAttr || ""))).length && (Object.defineProperty(a, "_lazyrias", {
value: d,
writable: !0
}), b && a.parentNode && (d.isPicture = "PICTURE" == a.parentNode.nodeName.toUpperCase())), a._lazyrias
}, g = function (b) {
var d = a.devicePixelRatio || 1, e = c.getX && c.getX(b);
return Math.min(e || d, 2.4, d)
}, h = function (b, c) {
var h, i, j, k, l, m;
if (l = b._lazyrias, l.isPicture && a.matchMedia) for (i = 0, h = b.parentNode.getElementsByTagName("source"), j = h.length; i < j; i++) if (f(h[i]) && !h[i].getAttribute("type") && (!(k = h[i].getAttribute("media")) || (matchMedia(k) || {}).matches)) {
l = h[i]._lazyrias;
break
}
return (!l.w || l.w < c) && (l.w = c, l.d = g(b), m = e(l.sort(d))), m
}, j = function (d) {
if (d.detail.instance == c) {
var e, g = d.target;
if (!u && (a.respimage || a.picturefill || lazySizesConfig.pf)) return void b.removeEventListener("lazybeforesizes", j);
("_lazyrias" in g || d.detail.dataAttr && f(g, !0)) && (e = h(g, d.detail.width)) && e.u && g._lazyrias.cur != e.u && (g._lazyrias.cur = e.u, e.cached = !0, c.rAF(function () {
g.setAttribute(i.srcAttr, e.u), g.setAttribute("src", e.u)
}))
}
};
return v ? j = function () {
} : addEventListener("lazybeforesizes", j), j
}()
});
/*! ls.bgset.min.js - v4.1.8 */
!function (a, b) {
var c = function () {
b(a.lazySizes), a.removeEventListener("lazyunveilread", c, !0)
};
b = b.bind(null, a, a.document), "object" == typeof module && module.exports ? b(require("lazysizes")) : a.lazySizes ? c() : a.addEventListener("lazyunveilread", c, !0)
}(window, function (a, b, c) {
"use strict";
if (a.addEventListener) {
var d = /\s+/g, e = /\s*\|\s+|\s+\|\s*/g, f = /^(.+?)(?:\s+\[\s*(.+?)\s*\])(?:\s+\[\s*(.+?)\s*\])?$/,
g = /^\s*\(*\s*type\s*:\s*(.+?)\s*\)*\s*$/, h = /\(|\)|'/, i = {contain: 1, cover: 1}, j = function (a) {
var b = c.gW(a, a.parentNode);
return (!a._lazysizesWidth || b > a._lazysizesWidth) && (a._lazysizesWidth = b), a._lazysizesWidth
}, k = function (a) {
var b;
return b = (getComputedStyle(a) || {
getPropertyValue: function () {
}
}).getPropertyValue("background-size"), !i[b] && i[a.style.backgroundSize] && (b = a.style.backgroundSize), b
}, l = function (a, b) {
if (b) {
var c = b.match(g);
c && c[1] ? a.setAttribute("type", c[1]) : a.setAttribute("media", lazySizesConfig.customMedia[b] || b)
}
}, m = function (a, c, g) {
var h = b.createElement("picture"), i = c.getAttribute(lazySizesConfig.sizesAttr),
j = c.getAttribute("data-ratio"), k = c.getAttribute("data-optimumx");
c._lazybgset && c._lazybgset.parentNode == c && c.removeChild(c._lazybgset), Object.defineProperty(g, "_lazybgset", {
value: c,
writable: !0
}), Object.defineProperty(c, "_lazybgset", {
value: h,
writable: !0
}), a = a.replace(d, " ").split(e), h.style.display = "none", g.className = lazySizesConfig.lazyClass, 1 != a.length || i || (i = "auto"), a.forEach(function (a) {
var c, d = b.createElement("source");
i && "auto" != i && d.setAttribute("sizes", i), (c = a.match(f)) ? (d.setAttribute(lazySizesConfig.srcsetAttr, c[1]), l(d, c[2]), l(d, c[3])) : d.setAttribute(lazySizesConfig.srcsetAttr, a), h.appendChild(d)
}), i && (g.setAttribute(lazySizesConfig.sizesAttr, i), c.removeAttribute(lazySizesConfig.sizesAttr), c.removeAttribute("sizes")), k && g.setAttribute("data-optimumx", k), j && g.setAttribute("data-ratio", j), h.appendChild(g), c.appendChild(h)
}, n = function (a) {
if (a.target._lazybgset) {
var b = a.target, d = b._lazybgset, e = b.currentSrc || b.src;
if (e) {
var f = c.fire(d, "bgsetproxy", {src: e, useSrc: h.test(e) ? JSON.stringify(e) : e});
f.defaultPrevented || (d.style.backgroundImage = "url(" + f.detail.useSrc + ")")
}
b._lazybgsetLoading && (c.fire(d, "_lazyloaded", {}, !1, !0), delete b._lazybgsetLoading)
}
};
addEventListener("lazybeforeunveil", function (a) {
var d, e, f;
!a.defaultPrevented && (d = a.target.getAttribute("data-bgset")) && (f = a.target, e = b.createElement("img"), e.alt = "", e._lazybgsetLoading = !0, a.detail.firesLoad = !0, m(d, f, e), setTimeout(function () {
c.loader.unveil(e), c.rAF(function () {
c.fire(e, "_lazyloaded", {}, !0, !0), e.complete && n({target: e})
})
}))
}), b.addEventListener("load", n, !0), a.addEventListener("lazybeforesizes", function (a) {
if (a.detail.instance == c && a.target._lazybgset && a.detail.dataAttr) {
var b = a.target._lazybgset, d = k(b);
i[d] && (a.target._lazysizesParentFit = d, c.rAF(function () {
a.target.setAttribute("data-parent-fit", d), a.target._lazysizesParentFit && delete a.target._lazysizesParentFit
}))
}
}, !0), b.documentElement.addEventListener("lazybeforesizes", function (a) {
!a.defaultPrevented && a.target._lazybgset && a.detail.instance == c && (a.detail.width = j(a.target._lazybgset))
})
}
});
/*! ls.object-fit.min.js - v4.1.8 */
!function (a, b) {
var c = function (d) {
b(a.lazySizes, d), a.removeEventListener("lazyunveilread", c, !0)
};
b = b.bind(null, a, a.document), "object" == typeof module && module.exports ? b(require("lazysizes")) : a.lazySizes ? c() : a.addEventListener("lazyunveilread", c, !0)
}(window, function (a, b, c, d) {
"use strict";
function e(a) {
var b = getComputedStyle(a, null) || {}, c = b.fontFamily || "", d = c.match(j) || "",
e = d && c.match(k) || "";
return e && (e = e[1]), {fit: d && d[1] || "", position: n[e] || e || "center"}
}
function f(a, b) {
var d, e, f = c.cfg, g = a.cloneNode(!1), h = g.style, i = function () {
var b = a.currentSrc || a.src;
b && e !== b && (e = b, h.backgroundImage = "url(" + (m.test(b) ? JSON.stringify(b) : b) + ")", d || (d = !0, c.rC(g, f.loadingClass), c.aC(g, f.loadedClass)))
}, j = function () {
c.rAF(i)
};
a._lazysizesParentFit = b.fit, a.addEventListener("lazyloaded", j, !0), a.addEventListener("load", j, !0), g.addEventListener("load", function () {
var a = g.currentSrc || g.src;
a && a != l && (g.src = l, g.srcset = "")
}), c.rAF(function () {
var d = a, e = a.parentNode;
"PICTURE" == e.nodeName.toUpperCase() && (d = e, e = e.parentNode), c.rC(g, f.loadedClass), c.rC(g, f.lazyClass), c.aC(g, f.loadingClass), c.aC(g, f.objectFitClass || "lazysizes-display-clone"), g.getAttribute(f.srcsetAttr) && g.setAttribute(f.srcsetAttr, ""), g.getAttribute(f.srcAttr) && g.setAttribute(f.srcAttr, ""), g.src = l, g.srcset = "", h.backgroundRepeat = "no-repeat", h.backgroundPosition = b.position, h.backgroundSize = b.fit, d.style.display = "none", a.setAttribute("data-parent-fit", b.fit), a.setAttribute("data-parent-container", "prev"), e.insertBefore(g, d), a._lazysizesParentFit && delete a._lazysizesParentFit, a.complete && i()
})
}
var g = b.createElement("a").style, h = "objectFit" in g, i = h && "objectPosition" in g,
j = /object-fit["']*\s*:\s*["']*(contain|cover)/, k = /object-position["']*\s*:\s*["']*(.+?)(?=($|,|'|"|;))/,
l = "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==", m = /\(|\)|'/,
n = {center: "center", "50% 50%": "center"};
if (!h || !i) {
var o = function (a) {
if (a.detail.instance == c) {
var b = a.target, d = e(b);
!d.fit || h && "center" == d.position || f(b, d)
}
};
a.addEventListener("lazyunveilread", o, !0), d && d.detail && o(d)
}
});
/*! ls.parent-fit.min.js - v4.1.8 */
!function (a, b) {
var c = function () {
b(a.lazySizes), a.removeEventListener("lazyunveilread", c, !0)
};
b = b.bind(null, a, a.document), "object" == typeof module && module.exports ? b(require("lazysizes")) : a.lazySizes ? c() : a.addEventListener("lazyunveilread", c, !0)
}(window, function (a, b, c) {
"use strict";
if (a.addEventListener) {
var d = /\s+(\d+)(w|h)\s+(\d+)(w|h)/, e = /parent-fit["']*\s*:\s*["']*(contain|cover|width)/,
f = /parent-container["']*\s*:\s*["']*(.+?)(?=(\s|$|,|'|"|;))/, g = /^picture$/i, h = function (a) {
return getComputedStyle(a, null) || {}
}, i = {
getParent: function (b, c) {
var d = b, e = b.parentNode;
return c && "prev" != c || !e || !g.test(e.nodeName || "") || (e = e.parentNode), "self" != c && (d = "prev" == c ? b.previousElementSibling : c && (e.closest || a.jQuery) ? (e.closest ? e.closest(c) : jQuery(e).closest(c)[0]) || e : e), d
}, getFit: function (a) {
var b, c, d = h(a), g = d.content || d.fontFamily,
j = {fit: a._lazysizesParentFit || a.getAttribute("data-parent-fit")};
return !j.fit && g && (b = g.match(e)) && (j.fit = b[1]), j.fit ? (c = a._lazysizesParentContainer || a.getAttribute("data-parent-container"), !c && g && (b = g.match(f)) && (c = b[1]), j.parent = i.getParent(a, c)) : j.fit = d.objectFit, j
}, getImageRatio: function (b) {
var c, e, f, h, i, j, k, l = b.parentNode,
m = l && g.test(l.nodeName || "") ? l.querySelectorAll("source, img") : [b];
for (c = 0; c < m.length; c++) if (b = m[c], e = b.getAttribute(lazySizesConfig.srcsetAttr) || b.getAttribute("srcset") || b.getAttribute("data-pfsrcset") || b.getAttribute("data-risrcset") || "", f = b._lsMedia || b.getAttribute("media"), f = lazySizesConfig.customMedia[b.getAttribute("data-media") || f] || f, e && (!f || (a.matchMedia && matchMedia(f) || {}).matches)) {
h = parseFloat(b.getAttribute("data-aspectratio")), h || (i = e.match(d), i ? "w" == i[2] ? (j = i[1], k = i[3]) : (j = i[3], k = i[1]) : (j = b.getAttribute("width"), k = b.getAttribute("height")), h = j / k);
break
}
return h
}, calculateSize: function (a, b) {
var c, d, e, f, g = this.getFit(a), h = g.fit, i = g.parent;
return "width" == h || ("contain" == h || "cover" == h) && (e = this.getImageRatio(a)) ? (i ? b = i.clientWidth : i = a, f = b, "width" == h ? f = b : (d = i.clientHeight) > 40 && (c = b / d) && ("cover" == h && c < e || "contain" == h && c > e) && (f = b * (e / c)), f) : b
}
};
c.parentFit = i, b.addEventListener("lazybeforesizes", function (a) {
if (!a.defaultPrevented && a.detail.instance == c) {
var b = a.target;
a.detail.width = i.calculateSize(b, a.detail.width)
}
})
}
});
/*! ls.respimg.min.js - v4.1.8 */
!function (a, b) {
var c = function () {
b(a.lazySizes), a.removeEventListener("lazyunveilread", c, !0)
};
b = b.bind(null, a, a.document), "object" == typeof module && module.exports ? b(require("lazysizes")) : a.lazySizes ? c() : a.addEventListener("lazyunveilread", c, !0)
}(window, function (a, b, c) {
"use strict";
var d, e = c && c.cfg, f = b.createElement("img"), g = "sizes" in f && "srcset" in f, h = /\s+\d+h/g,
i = function () {
var a = /\s+(\d+)(w|h)\s+(\d+)(w|h)/, d = Array.prototype.forEach;
return function () {
var e = b.createElement("img"), f = function (b) {
var c, d, e = b.getAttribute(lazySizesConfig.srcsetAttr);
e && (d = e.match(a)) && (c = "w" == d[2] ? d[1] / d[3] : d[3] / d[1], c && b.setAttribute("data-aspectratio", c), b.setAttribute(lazySizesConfig.srcsetAttr, e.replace(h, "")))
}, g = function (a) {
if (a.detail.instance == c) {
var b = a.target.parentNode;
b && "PICTURE" == b.nodeName && d.call(b.getElementsByTagName("source"), f), f(a.target)
}
}, i = function () {
e.currentSrc && b.removeEventListener("lazybeforeunveil", g)
};
b.addEventListener("lazybeforeunveil", g), e.onload = i, e.onerror = i, e.srcset = "data:,a 1w 1h", e.complete && i()
}
}();
if (e.supportsType || (e.supportsType = function (a) {
return !a
}), a.HTMLPictureElement && g) return void (!c.hasHDescriptorFix && b.msElementsFromPoint && (c.hasHDescriptorFix = !0, i()));
a.picturefill || e.pf || (e.pf = function (b) {
var c, e;
if (!a.picturefill) for (c = 0, e = b.elements.length; c < e; c++) d(b.elements[c])
}, d = function () {
var f = function (a, b) {
return a.w - b.w
}, i = /^\s*\d+\.*\d*px\s*$/, j = function (a) {
var b, c, d = a.length, e = a[d - 1], f = 0;
for (f; f < d; f++) if (e = a[f], e.d = e.w / a.w, e.d >= a.d) {
!e.cached && (b = a[f - 1]) && b.d > a.d - .13 * Math.pow(a.d, 2.2) && (c = Math.pow(b.d - .6, 1.6), b.cached && (b.d += .15 * c), b.d + (e.d - a.d) * c > a.d && (e = b));
break
}
return e
}, k = function () {
var a, b = /(([^,\s].[^\s]+)\s+(\d+)w)/g, c = /\s/, d = function (b, c, d, e) {
a.push({c: c, u: d, w: 1 * e})
};
return function (e) {
return a = [], e = e.trim(), e.replace(h, "").replace(b, d), a.length || !e || c.test(e) || a.push({
c: e,
u: e,
w: 99
}), a
}
}(), l = function () {
l.init || (l.init = !0, addEventListener("resize", function () {
var a, c = b.getElementsByClassName("lazymatchmedia"), e = function () {
var a, b;
for (a = 0, b = c.length; a < b; a++) d(c[a])
};
return function () {
clearTimeout(a), a = setTimeout(e, 66)
}
}()))
}, m = function (b, d) {
var f, g = b.getAttribute("srcset") || b.getAttribute(e.srcsetAttr);
!g && d && (g = b._lazypolyfill ? b._lazypolyfill._set : b.getAttribute(e.srcAttr) || b.getAttribute("src")), b._lazypolyfill && b._lazypolyfill._set == g || (f = k(g || ""), d && b.parentNode && (f.isPicture = "PICTURE" == b.parentNode.nodeName.toUpperCase(), f.isPicture && a.matchMedia && (c.aC(b, "lazymatchmedia"), l())), f._set = g, Object.defineProperty(b, "_lazypolyfill", {
value: f,
writable: !0
}))
}, n = function (b) {
var d = a.devicePixelRatio || 1, e = c.getX && c.getX(b);
return Math.min(e || d, 2.5, d)
}, o = function (b) {
return a.matchMedia ? (o = function (a) {
return !a || (matchMedia(a) || {}).matches
})(b) : !b
}, p = function (a) {
var b, d, g, h, k, l, p;
if (h = a, m(h, !0), k = h._lazypolyfill, k.isPicture) for (d = 0, b = a.parentNode.getElementsByTagName("source"), g = b.length; d < g; d++) if (e.supportsType(b[d].getAttribute("type"), a) && o(b[d].getAttribute("media"))) {
h = b[d], m(h), k = h._lazypolyfill;
break
}
return k.length > 1 ? (p = h.getAttribute("sizes") || "", p = i.test(p) && parseInt(p, 10) || c.gW(a, a.parentNode), k.d = n(a), !k.src || !k.w || k.w < p ? (k.w = p, l = j(k.sort(f)), k.src = l) : l = k.src) : l = k[0], l
}, q = function (a) {
if (!g || !a.parentNode || "PICTURE" == a.parentNode.nodeName.toUpperCase()) {
var b = p(a);
b && b.u && a._lazypolyfill.cur != b.u && (a._lazypolyfill.cur = b.u, b.cached = !0, a.setAttribute(e.srcAttr, b.u), a.setAttribute("src", b.u))
}
};
return q.parse = k, q
}(), e.loadedClass && e.loadingClass && function () {
var a = [];
['img[sizes$="px"][srcset].', "picture > img:not([srcset])."].forEach(function (b) {
a.push(b + e.loadedClass), a.push(b + e.loadingClass)
}), e.pf({elements: b.querySelectorAll(a.join(", "))})
}())
});
/*!
* Modernizr v2.7.1
* www.modernizr.com
*
* Copyright (c) Faruk Ates, Paul Irish, Alex Sexton
* Available under the BSD and MIT licenses: www.modernizr.com/license/
*/
/*
* Modernizr tests which native CSS3 and HTML5 features are available in
* the current UA and makes the results available to you in two ways:
* as properties on a global Modernizr object, and as classes on the
* element. This information allows you to progressively enhance
* your pages with a granular level of control over the experience.
*
* Modernizr has an optional (not included) conditional resource loader
* called Modernizr.load(), based on Yepnope.js (yepnopejs.com).
* To get a build that includes Modernizr.load(), as well as choosing
* which tests to include, go to www.modernizr.com/download/
*
* Authors Faruk Ates, Paul Irish, Alex Sexton
* Contributors Ryan Seddon, Ben Alman
*/
window.Modernizr = (function (window, document, undefined) {
var version = '2.7.1',
Modernizr = {},
/*>>cssclasses*/
// option for enabling the HTML classes to be added
enableClasses = true,
/*>>cssclasses*/
docElement = document.documentElement,
/**
* Create our "modernizr" element that we do most feature tests on.
*/
mod = 'modernizr',
modElem = document.createElement(mod),
mStyle = modElem.style,
/**
* Create the input element for various Web Forms feature tests.
*/
inputElem /*>>inputelem*/ = document.createElement('input') /*>>inputelem*/,
/*>>smile*/
smile = ':)',
/*>>smile*/
toString = {}.toString,
// TODO :: make the prefixes more granular
/*>>prefixes*/
// List of property values to set for css tests. See ticket #21
prefixes = ' -webkit- -moz- -o- -ms- '.split(' '),
/*>>prefixes*/
/*>>domprefixes*/
// Following spec is to expose vendor-specific style properties as:
// elem.style.WebkitBorderRadius
// and the following would be incorrect:
// elem.style.webkitBorderRadius
// Webkit ghosts their properties in lowercase but Opera & Moz do not.
// Microsoft uses a lowercase `ms` instead of the correct `Ms` in IE8+
// erik.eae.net/archives/2008/03/10/21.48.10/
// More here: github.com/Modernizr/Modernizr/issues/issue/21
omPrefixes = 'Webkit Moz O ms',
cssomPrefixes = omPrefixes.split(' '),
domPrefixes = omPrefixes.toLowerCase().split(' '),
/*>>domprefixes*/
/*>>ns*/
ns = {'svg': 'http://www.w3.org/2000/svg'},
/*>>ns*/
tests = {},
inputs = {},
attrs = {},
classes = [],
slice = classes.slice,
featureName, // used in testing loop
/*>>teststyles*/
// Inject element with style element and some CSS rules
injectElementWithStyles = function (rule, callback, nodes, testnames) {
var style, ret, node, docOverflow,
div = document.createElement('div'),
// After page load injecting a fake body doesn't work so check if body exists
body = document.body,
// IE6 and 7 won't return offsetWidth or offsetHeight unless it's in the body element, so we fake it.
fakeBody = body || document.createElement('body');
if (parseInt(nodes, 10)) {
// In order not to give false positives we create a node for each test
// This also allows the method to scale for unspecified uses
while (nodes--) {
node = document.createElement('div');
node.id = testnames ? testnames[nodes] : mod + (nodes + 1);
div.appendChild(node);
}
}
// '].join('');
div.id = mod;
// IE6 will false positive on some tests due to the style element inside the test div somehow interfering offsetHeight, so insert it into body or fakebody.
// Opera will act all quirky when injecting elements in documentElement when page is served as xml, needs fakebody too. #270
(body ? div : fakeBody).innerHTML += style;
fakeBody.appendChild(div);
if (!body) {
//avoid crashing IE8, if background image is used
fakeBody.style.background = '';
//Safari 5.13/5.1.4 OSX stops loading if ::-webkit-scrollbar is used and scrollbars are visible
fakeBody.style.overflow = 'hidden';
docOverflow = docElement.style.overflow;
docElement.style.overflow = 'hidden';
docElement.appendChild(fakeBody);
}
ret = callback(div, rule);
// If this is done after page load we don't want to remove the body so check if body exists
if (!body) {
fakeBody.parentNode.removeChild(fakeBody);
docElement.style.overflow = docOverflow;
} else {
div.parentNode.removeChild(div);
}
return !!ret;
},
/*>>teststyles*/
/*>>mq*/
// adapted from matchMedia polyfill
// by Scott Jehl and Paul Irish
// gist.github.com/786768
testMediaQuery = function (mq) {
var matchMedia = window.matchMedia || window.msMatchMedia;
if (matchMedia) {
return matchMedia(mq).matches;
}
var bool;
injectElementWithStyles('@media ' + mq + ' { #' + mod + ' { position: absolute; } }', function (node) {
bool = (window.getComputedStyle ?
getComputedStyle(node, null) :
node.currentStyle)['position'] == 'absolute';
});
return bool;
},
/*>>mq*/
/*>>hasevent*/
//
// isEventSupported determines if a given element supports the given event
// kangax.github.com/iseventsupported/
//
// The following results are known incorrects:
// Modernizr.hasEvent("webkitTransitionEnd", elem) // false negative
// Modernizr.hasEvent("textInput") // in Webkit. github.com/Modernizr/Modernizr/issues/333
// ...
isEventSupported = (function () {
var TAGNAMES = {
'select': 'input', 'change': 'input',
'submit': 'form', 'reset': 'form',
'error': 'img', 'load': 'img', 'abort': 'img'
};
function isEventSupported(eventName, element) {
element = element || document.createElement(TAGNAMES[eventName] || 'div');
eventName = 'on' + eventName;
// When using `setAttribute`, IE skips "unload", WebKit skips "unload" and "resize", whereas `in` "catches" those
var isSupported = eventName in element;
if (!isSupported) {
// If it has no `setAttribute` (i.e. doesn't implement Node interface), try generic element
if (!element.setAttribute) {
element = document.createElement('div');
}
if (element.setAttribute && element.removeAttribute) {
element.setAttribute(eventName, '');
isSupported = is(element[eventName], 'function');
// If property was created, "remove it" (by setting value to `undefined`)
if (!is(element[eventName], 'undefined')) {
element[eventName] = undefined;
}
element.removeAttribute(eventName);
}
}
element = null;
return isSupported;
}
return isEventSupported;
})(),
/*>>hasevent*/
// TODO :: Add flag for hasownprop ? didn't last time
// hasOwnProperty shim by kangax needed for Safari 2.0 support
_hasOwnProperty = ({}).hasOwnProperty, hasOwnProp;
if (!is(_hasOwnProperty, 'undefined') && !is(_hasOwnProperty.call, 'undefined')) {
hasOwnProp = function (object, property) {
return _hasOwnProperty.call(object, property);
};
} else {
hasOwnProp = function (object, property) { /* yes, this can give false positives/negatives, but most of the time we don't care about those */
return ((property in object) && is(object.constructor.prototype[property], 'undefined'));
};
}
// Adapted from ES5-shim https://github.com/kriskowal/es5-shim/blob/master/es5-shim.js
// es5.github.com/#x15.3.4.5
if (!Function.prototype.bind) {
Function.prototype.bind = function bind(that) {
var target = this;
if (typeof target != "function") {
throw new TypeError();
}
var args = slice.call(arguments, 1),
bound = function () {
if (this instanceof bound) {
var F = function () {
};
F.prototype = target.prototype;
var self = new F();
var result = target.apply(
self,
args.concat(slice.call(arguments))
);
if (Object(result) === result) {
return result;
}
return self;
} else {
return target.apply(
that,
args.concat(slice.call(arguments))
);
}
};
return bound;
};
}
/**
* setCss applies given styles to the Modernizr DOM node.
*/
function setCss(str) {
mStyle.cssText = str;
}
/**
* setCssAll extrapolates all vendor-specific css strings.
*/
function setCssAll(str1, str2) {
return setCss(prefixes.join(str1 + ';') + (str2 || ''));
}
/**
* is returns a boolean for if typeof obj is exactly type.
*/
function is(obj, type) {
return typeof obj === type;
}
/**
* contains returns a boolean for if substr is found within str.
*/
function contains(str, substr) {
return !!~('' + str).indexOf(substr);
}
/*>>testprop*/
// testProps is a generic CSS / DOM property test.
// In testing support for a given CSS property, it's legit to test:
// `elem.style[styleName] !== undefined`
// If the property is supported it will return an empty string,
// if unsupported it will return undefined.
// We'll take advantage of this quick test and skip setting a style
// on our modernizr element, but instead just testing undefined vs
// empty string.
// Because the testing of the CSS property names (with "-", as
// opposed to the camelCase DOM properties) is non-portable and
// non-standard but works in WebKit and IE (but not Gecko or Opera),
// we explicitly reject properties with dashes so that authors
// developing in WebKit or IE first don't end up with
// browser-specific content by accident.
function testProps(props, prefixed) {
for (var i in props) {
var prop = props[i];
if (!contains(prop, "-") && mStyle[prop] !== undefined) {
return prefixed == 'pfx' ? prop : true;
}
}
return false;
}
/*>>testprop*/
// TODO :: add testDOMProps
/**
* testDOMProps is a generic DOM property test; if a browser supports
* a certain property, it won't return undefined for it.
*/
function testDOMProps(props, obj, elem) {
for (var i in props) {
var item = obj[props[i]];
if (item !== undefined) {
// return the property name as a string
if (elem === false) return props[i];
// let's bind a function
if (is(item, 'function')) {
// default to autobind unless override
return item.bind(elem || obj);
}
// return the unbound function or obj or value
return item;
}
}
return false;
}
/*>>testallprops*/
/**
* testPropsAll tests a list of DOM properties we want to check against.
* We specify literally ALL possible (known and/or likely) properties on
* the element including the non-vendor prefixed one, for forward-
* compatibility.
*/
function testPropsAll(prop, prefixed, elem) {
var ucProp = prop.charAt(0).toUpperCase() + prop.slice(1),
props = (prop + ' ' + cssomPrefixes.join(ucProp + ' ') + ucProp).split(' ');
// did they call .prefixed('boxSizing') or are we just testing a prop?
if (is(prefixed, "string") || is(prefixed, "undefined")) {
return testProps(props, prefixed);
// otherwise, they called .prefixed('requestAnimationFrame', window[, elem])
} else {
props = (prop + ' ' + (domPrefixes).join(ucProp + ' ') + ucProp).split(' ');
return testDOMProps(props, prefixed, elem);
}
}
/*>>testallprops*/
/**
* Tests
* -----
*/
// The *new* flexbox
// dev.w3.org/csswg/css3-flexbox
tests['flexbox'] = function () {
return testPropsAll('flexWrap');
};
// The *old* flexbox
// www.w3.org/TR/2009/WD-css3-flexbox-20090723/
tests['flexboxlegacy'] = function () {
return testPropsAll('boxDirection');
};
// On the S60 and BB Storm, getContext exists, but always returns undefined
// so we actually have to call getContext() to verify
// github.com/Modernizr/Modernizr/issues/issue/97/
tests['canvas'] = function () {
var elem = document.createElement('canvas');
return !!(elem.getContext && elem.getContext('2d'));
};
tests['canvastext'] = function () {
return !!(Modernizr['canvas'] && is(document.createElement('canvas').getContext('2d').fillText, 'function'));
};
// webk.it/70117 is tracking a legit WebGL feature detect proposal
// We do a soft detect which may false positive in order to avoid
// an expensive context creation: bugzil.la/732441
tests['webgl'] = function () {
return !!window.WebGLRenderingContext;
};
/*
* The Modernizr.touch test only indicates if the browser supports
* touch events, which does not necessarily reflect a touchscreen
* device, as evidenced by tablets running Windows 7 or, alas,
* the Palm Pre / WebOS (touch) phones.
*
* Additionally, Chrome (desktop) used to lie about its support on this,
* but that has since been rectified: crbug.com/36415
*
* We also test for Firefox 4 Multitouch Support.
*
* For more info, see: modernizr.github.com/Modernizr/touch.html
*/
tests['touch'] = function () {
var bool;
if (('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch) {
bool = true;
} else {
injectElementWithStyles(['@media (', prefixes.join('touch-enabled),('), mod, ')', '{#modernizr{top:9px;position:absolute}}'].join(''), function (node) {
bool = node.offsetTop === 9;
});
}
return bool;
};
// geolocation is often considered a trivial feature detect...
// Turns out, it's quite tricky to get right:
//
// Using !!navigator.geolocation does two things we don't want. It:
// 1. Leaks memory in IE9: github.com/Modernizr/Modernizr/issues/513
// 2. Disables page caching in WebKit: webk.it/43956
//
// Meanwhile, in Firefox < 8, an about:config setting could expose
// a false positive that would throw an exception: bugzil.la/688158
tests['geolocation'] = function () {
return 'geolocation' in navigator;
};
tests['postmessage'] = function () {
return !!window.postMessage;
};
// Chrome incognito mode used to throw an exception when using openDatabase
// It doesn't anymore.
tests['websqldatabase'] = function () {
return !!window.openDatabase;
};
// Vendors had inconsistent prefixing with the experimental Indexed DB:
// - Webkit's implementation is accessible through webkitIndexedDB
// - Firefox shipped moz_indexedDB before FF4b9, but since then has been mozIndexedDB
// For speed, we don't test the legacy (and beta-only) indexedDB
tests['indexedDB'] = function () {
return !!testPropsAll("indexedDB", window);
};
// documentMode logic from YUI to filter out IE8 Compat Mode
// which false positives.
tests['hashchange'] = function () {
return isEventSupported('hashchange', window) && (document.documentMode === undefined || document.documentMode > 7);
};
// Per 1.6:
// This used to be Modernizr.historymanagement but the longer
// name has been deprecated in favor of a shorter and property-matching one.
// The old API is still available in 1.6, but as of 2.0 will throw a warning,
// and in the first release thereafter disappear entirely.
tests['history'] = function () {
return !!(window.history && history.pushState);
};
tests['draganddrop'] = function () {
var div = document.createElement('div');
return ('draggable' in div) || ('ondragstart' in div && 'ondrop' in div);
};
// FF3.6 was EOL'ed on 4/24/12, but the ESR version of FF10
// will be supported until FF19 (2/12/13), at which time, ESR becomes FF17.
// FF10 still uses prefixes, so check for it until then.
// for more ESR info, see: mozilla.org/en-US/firefox/organizations/faq/
tests['websockets'] = function () {
return 'WebSocket' in window || 'MozWebSocket' in window;
};
// css-tricks.com/rgba-browser-support/
tests['rgba'] = function () {
// Set an rgba() color and check the returned value
setCss('background-color:rgba(150,255,150,.5)');
return contains(mStyle.backgroundColor, 'rgba');
};
tests['hsla'] = function () {
// Same as rgba(), in fact, browsers re-map hsla() to rgba() internally,
// except IE9 who retains it as hsla
setCss('background-color:hsla(120,40%,100%,.5)');
return contains(mStyle.backgroundColor, 'rgba') || contains(mStyle.backgroundColor, 'hsla');
};
tests['multiplebgs'] = function () {
// Setting multiple images AND a color on the background shorthand property
// and then querying the style.background property value for the number of
// occurrences of "url(" is a reliable method for detecting ACTUAL support for this!
setCss('background:url(https://),url(https://),red url(https://)');
// If the UA supports multiple backgrounds, there should be three occurrences
// of the string "url(" in the return value for elemStyle.background
return (/(url\s*\(.*?){3}/).test(mStyle.background);
};
// this will false positive in Opera Mini
// github.com/Modernizr/Modernizr/issues/396
tests['backgroundsize'] = function () {
return testPropsAll('backgroundSize');
};
tests['borderimage'] = function () {
return testPropsAll('borderImage');
};
// Super comprehensive table about all the unique implementations of
// border-radius: muddledramblings.com/table-of-css3-border-radius-compliance
tests['borderradius'] = function () {
return testPropsAll('borderRadius');
};
// WebOS unfortunately false positives on this test.
tests['boxshadow'] = function () {
return testPropsAll('boxShadow');
};
// FF3.0 will false positive on this test
tests['textshadow'] = function () {
return document.createElement('div').style.textShadow === '';
};
tests['opacity'] = function () {
// Browsers that actually have CSS Opacity implemented have done so
// according to spec, which means their return values are within the
// range of [0.0,1.0] - including the leading zero.
setCssAll('opacity:.55');
// The non-literal . in this regex is intentional:
// German Chrome returns this value as 0,55
// github.com/Modernizr/Modernizr/issues/#issue/59/comment/516632
return (/^0.55$/).test(mStyle.opacity);
};
// Note, Android < 4 will pass this test, but can only animate
// a single property at a time
// daneden.me/2011/12/putting-up-with-androids-bullshit/
tests['cssanimations'] = function () {
return testPropsAll('animationName');
};
tests['csscolumns'] = function () {
return testPropsAll('columnCount');
};
tests['cssgradients'] = function () {
/**
* For CSS Gradients syntax, please see:
* webkit.org/blog/175/introducing-css-gradients/
* developer.mozilla.org/en/CSS/-moz-linear-gradient
* developer.mozilla.org/en/CSS/-moz-radial-gradient
* dev.w3.org/csswg/css3-images/#gradients-
*/
var str1 = 'background-image:',
str2 = 'gradient(linear,left top,right bottom,from(#9f9),to(white));',
str3 = 'linear-gradient(left top,#9f9, white);';
setCss(
// legacy webkit syntax (FIXME: remove when syntax not in use anymore)
(str1 + '-webkit- '.split(' ').join(str2 + str1) +
// standard syntax // trailing 'background-image:'
prefixes.join(str3 + str1)).slice(0, -str1.length)
);
return contains(mStyle.backgroundImage, 'gradient');
};
tests['cssreflections'] = function () {
return testPropsAll('boxReflect');
};
tests['csstransforms'] = function () {
return !!testPropsAll('transform');
};
tests['csstransforms3d'] = function () {
var ret = !!testPropsAll('perspective');
// Webkit's 3D transforms are passed off to the browser's own graphics renderer.
// It works fine in Safari on Leopard and Snow Leopard, but not in Chrome in
// some conditions. As a result, Webkit typically recognizes the syntax but
// will sometimes throw a false positive, thus we must do a more thorough check:
if (ret && 'webkitPerspective' in docElement.style) {
// Webkit allows this media query to succeed only if the feature is enabled.
// `@media (transform-3d),(-webkit-transform-3d){ ... }`
injectElementWithStyles('@media (transform-3d),(-webkit-transform-3d){#modernizr{left:9px;position:absolute;height:3px;}}', function (node, rule) {
ret = node.offsetLeft === 9 && node.offsetHeight === 3;
});
}
return ret;
};
tests['csstransitions'] = function () {
return testPropsAll('transition');
};
/*>>fontface*/
// @font-face detection routine by Diego Perini
// javascript.nwbox.com/CSSSupport/
// false positives:
// WebOS github.com/Modernizr/Modernizr/issues/342
// WP7 github.com/Modernizr/Modernizr/issues/538
tests['fontface'] = function () {
var bool;
injectElementWithStyles('@font-face {font-family:"font";src:url("https://")}', function (node, rule) {
var style = document.getElementById('smodernizr'),
sheet = style.sheet || style.styleSheet,
cssText = sheet ? (sheet.cssRules && sheet.cssRules[0] ? sheet.cssRules[0].cssText : sheet.cssText || '') : '';
bool = /src/i.test(cssText) && cssText.indexOf(rule.split(' ')[0]) === 0;
});
return bool;
};
/*>>fontface*/
// CSS generated content detection
tests['generatedcontent'] = function () {
var bool;
injectElementWithStyles(['#', mod, '{font:0/0 a}#', mod, ':after{content:"', smile, '";visibility:hidden;font:3px/1 a}'].join(''), function (node) {
bool = node.offsetHeight >= 3;
});
return bool;
};
// These tests evaluate support of the video/audio elements, as well as
// testing what types of content they support.
//
// We're using the Boolean constructor here, so that we can extend the value
// e.g. Modernizr.video // true
// Modernizr.video.ogg // 'probably'
//
// Codec values from : github.com/NielsLeenheer/html5test/blob/9106a8/index.html#L845
// thx to NielsLeenheer and zcorpan
// Note: in some older browsers, "no" was a return value instead of empty string.
// It was live in FF3.5.0 and 3.5.1, but fixed in 3.5.2
// It was also live in Safari 4.0.0 - 4.0.4, but fixed in 4.0.5
tests['video'] = function () {
var elem = document.createElement('video'),
bool = false;
// IE9 Running on Windows Server SKU can cause an exception to be thrown, bug #224
try {
if (bool = !!elem.canPlayType) {
bool = new Boolean(bool);
bool.ogg = elem.canPlayType('video/ogg; codecs="theora"').replace(/^no$/, '');
// Without QuickTime, this value will be `undefined`. github.com/Modernizr/Modernizr/issues/546
bool.h264 = elem.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/^no$/, '');
bool.webm = elem.canPlayType('video/webm; codecs="vp8, vorbis"').replace(/^no$/, '');
}
} catch (e) {
}
return bool;
};
tests['audio'] = function () {
var elem = document.createElement('audio'),
bool = false;
try {
if (bool = !!elem.canPlayType) {
bool = new Boolean(bool);
bool.ogg = elem.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/, '');
bool.mp3 = elem.canPlayType('audio/mpeg;').replace(/^no$/, '');
// Mimetypes accepted:
// developer.mozilla.org/En/Media_formats_supported_by_the_audio_and_video_elements
// bit.ly/iphoneoscodecs
bool.wav = elem.canPlayType('audio/wav; codecs="1"').replace(/^no$/, '');
bool.m4a = (elem.canPlayType('audio/x-m4a;') ||
elem.canPlayType('audio/aac;')).replace(/^no$/, '');
}
} catch (e) {
}
return bool;
};
// In FF4, if disabled, window.localStorage should === null.
// Normally, we could not test that directly and need to do a
// `('localStorage' in window) && ` test first because otherwise Firefox will
// throw bugzil.la/365772 if cookies are disabled
// Also in iOS5 Private Browsing mode, attempting to use localStorage.setItem
// will throw the exception:
// QUOTA_EXCEEDED_ERRROR DOM Exception 22.
// Peculiarly, getItem and removeItem calls do not throw.
// Because we are forced to try/catch this, we'll go aggressive.
// Just FWIW: IE8 Compat mode supports these features completely:
// www.quirksmode.org/dom/html5.html
// But IE8 doesn't support either with local files
tests['localstorage'] = function () {
try {
localStorage.setItem(mod, mod);
localStorage.removeItem(mod);
return true;
} catch (e) {
return false;
}
};
tests['sessionstorage'] = function () {
try {
sessionStorage.setItem(mod, mod);
sessionStorage.removeItem(mod);
return true;
} catch (e) {
return false;
}
};
tests['webworkers'] = function () {
return !!window.Worker;
};
tests['applicationcache'] = function () {
return !!window.applicationCache;
};
// Thanks to Erik Dahlstrom
tests['svg'] = function () {
return !!document.createElementNS && !!document.createElementNS(ns.svg, 'svg').createSVGRect;
};
// specifically for SVG inline in HTML, not within XHTML
// test page: paulirish.com/demo/inline-svg
tests['inlinesvg'] = function () {
var div = document.createElement('div');
div.innerHTML = '';
return (div.firstChild && div.firstChild.namespaceURI) == ns.svg;
};
// SVG SMIL animation
tests['smil'] = function () {
return !!document.createElementNS && /SVGAnimate/.test(toString.call(document.createElementNS(ns.svg, 'animate')));
};
// This test is only for clip paths in SVG proper, not clip paths on HTML content
// demo: srufaculty.sru.edu/david.dailey/svg/newstuff/clipPath4.svg
// However read the comments to dig into applying SVG clippaths to HTML content here:
// github.com/Modernizr/Modernizr/issues/213#issuecomment-1149491
tests['svgclippaths'] = function () {
return !!document.createElementNS && /SVGClipPath/.test(toString.call(document.createElementNS(ns.svg, 'clipPath')));
};
/*>>webforms*/
// input features and input types go directly onto the ret object, bypassing the tests loop.
// Hold this guy to execute in a moment.
function webforms() {
/*>>input*/
// Run through HTML5's new input attributes to see if the UA understands any.
// We're using f which is the element created early on
// Mike Taylr has created a comprehensive resource for testing these attributes
// when applied to all input types:
// miketaylr.com/code/input-type-attr.html
// spec: www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary
// Only input placeholder is tested while textarea's placeholder is not.
// Currently Safari 4 and Opera 11 have support only for the input placeholder
// Both tests are available in feature-detects/forms-placeholder.js
Modernizr['input'] = (function (props) {
for (var i = 0, len = props.length; i < len; i++) {
attrs[props[i]] = !!(props[i] in inputElem);
}
if (attrs.list) {
// safari false positive's on datalist: webk.it/74252
// see also github.com/Modernizr/Modernizr/issues/146
attrs.list = !!(document.createElement('datalist') && window.HTMLDataListElement);
}
return attrs;
})('autocomplete autofocus list placeholder max min multiple pattern required step'.split(' '));
/*>>input*/
/*>>inputtypes*/
// Run through HTML5's new input types to see if the UA understands any.
// This is put behind the tests runloop because it doesn't return a
// true/false like all the other tests; instead, it returns an object
// containing each input type with its corresponding true/false value
// Big thanks to @miketaylr for the html5 forms expertise. miketaylr.com/
Modernizr['inputtypes'] = (function (props) {
for (var i = 0, bool, inputElemType, defaultView, len = props.length; i < len; i++) {
inputElem.setAttribute('type', inputElemType = props[i]);
bool = inputElem.type !== 'text';
// We first check to see if the type we give it sticks..
// If the type does, we feed it a textual value, which shouldn't be valid.
// If the value doesn't stick, we know there's input sanitization which infers a custom UI
if (bool) {
inputElem.value = smile;
inputElem.style.cssText = 'position:absolute;visibility:hidden;';
if (/^range$/.test(inputElemType) && inputElem.style.WebkitAppearance !== undefined) {
docElement.appendChild(inputElem);
defaultView = document.defaultView;
// Safari 2-4 allows the smiley as a value, despite making a slider
bool = defaultView.getComputedStyle &&
defaultView.getComputedStyle(inputElem, null).WebkitAppearance !== 'textfield' &&
// Mobile android web browser has false positive, so must
// check the height to see if the widget is actually there.
(inputElem.offsetHeight !== 0);
docElement.removeChild(inputElem);
} else if (/^(search|tel)$/.test(inputElemType)) {
// Spec doesn't define any special parsing or detectable UI
// behaviors so we pass these through as true
// Interestingly, opera fails the earlier test, so it doesn't
// even make it here.
} else if (/^(url|email)$/.test(inputElemType)) {
// Real url and email support comes with prebaked validation.
bool = inputElem.checkValidity && inputElem.checkValidity() === false;
} else {
// If the upgraded input compontent rejects the :) text, we got a winner
bool = inputElem.value != smile;
}
}
inputs[props[i]] = !!bool;
}
return inputs;
})('search tel url email datetime date month week time datetime-local number range color'.split(' '));
/*>>inputtypes*/
}
/*>>webforms*/
// End of test definitions
// -----------------------
// Run through all tests and detect their support in the current UA.
// todo: hypothetically we could be doing an array of tests and use a basic loop here.
for (var feature in tests) {
if (hasOwnProp(tests, feature)) {
// run the test, throw the return value into the Modernizr,
// then based on that boolean, define an appropriate className
// and push it into an array of classes we'll join later.
featureName = feature.toLowerCase();
Modernizr[featureName] = tests[feature]();
classes.push((Modernizr[featureName] ? '' : 'no-') + featureName);
}
}
/*>>webforms*/
// input tests need to run.
Modernizr.input || webforms();
/*>>webforms*/
/**
* addTest allows the user to define their own feature tests
* the result will be added onto the Modernizr object,
* as well as an appropriate className set on the html element
*
* @param feature - String naming the feature
* @param test - Function returning true if feature is supported, false if not
*/
Modernizr.addTest = function (feature, test) {
if (typeof feature == 'object') {
for (var key in feature) {
if (hasOwnProp(feature, key)) {
Modernizr.addTest(key, feature[key]);
}
}
} else {
feature = feature.toLowerCase();
if (Modernizr[feature] !== undefined) {
// we're going to quit if you're trying to overwrite an existing test
// if we were to allow it, we'd do this:
// var re = new RegExp("\\b(no-)?" + feature + "\\b");
// docElement.className = docElement.className.replace( re, '' );
// but, no rly, stuff 'em.
return Modernizr;
}
test = typeof test == 'function' ? test() : test;
if (typeof enableClasses !== "undefined" && enableClasses) {
docElement.className += ' ' + (test ? '' : 'no-') + feature;
}
Modernizr[feature] = test;
}
return Modernizr; // allow chaining.
};
// Reset modElem.cssText to nothing to reduce memory footprint.
setCss('');
modElem = inputElem = null;
/*>>shiv*/
/**
* @preserve HTML5 Shiv prev3.7.1 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed
*/
;(function (window, document) {
/*jshint evil:true */
/** version */
var version = '3.7.0';
/** Preset options */
var options = window.html5 || {};
/** Used to skip problem elements */
var reSkip = /^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i;
/** Not all elements can be cloned in IE **/
var saveClones = /^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i;
/** Detect whether the browser supports default html5 styles */
var supportsHtml5Styles;
/** Name of the expando, to work with multiple documents or to re-shiv one document */
var expando = '_html5shiv';
/** The id for the the documents expando */
var expanID = 0;
/** Cached data for each document */
var expandoData = {};
/** Detect whether the browser supports unknown elements */
var supportsUnknownElements;
(function () {
try {
var a = document.createElement('a');
a.innerHTML = '';
//if the hidden property is implemented we can assume, that the browser supports basic HTML5 Styles
supportsHtml5Styles = ('hidden' in a);
supportsUnknownElements = a.childNodes.length == 1 || (function () {
// assign a false positive if unable to shiv
(document.createElement)('a');
var frag = document.createDocumentFragment();
return (
typeof frag.cloneNode == 'undefined' ||
typeof frag.createDocumentFragment == 'undefined' ||
typeof frag.createElement == 'undefined'
);
}());
} catch (e) {
// assign a false positive if detection fails => unable to shiv
supportsHtml5Styles = true;
supportsUnknownElements = true;
}
}());
/*--------------------------------------------------------------------------*/
/**
* Creates a style sheet with the given CSS text and adds it to the document.
* @private
* @param {Document} ownerDocument The document.
* @param {String} cssText The CSS text.
* @returns {StyleSheet} The style element.
*/
function addStyleSheet(ownerDocument, cssText) {
var p = ownerDocument.createElement('p'),
parent = ownerDocument.getElementsByTagName('head')[0] || ownerDocument.documentElement;
p.innerHTML = 'x';
return parent.insertBefore(p.lastChild, parent.firstChild);
}
/**
* Returns the value of `html5.elements` as an array.
* @private
* @returns {Array} An array of shived element node names.
*/
function getElements() {
var elements = html5.elements;
return typeof elements == 'string' ? elements.split(' ') : elements;
}
/**
* Returns the data associated to the given document
* @private
* @param {Document} ownerDocument The document.
* @returns {Object} An object of data.
*/
function getExpandoData(ownerDocument) {
var data = expandoData[ownerDocument[expando]];
if (!data) {
data = {};
expanID++;
ownerDocument[expando] = expanID;
expandoData[expanID] = data;
}
return data;
}
/**
* returns a shived element for the given nodeName and document
* @memberOf html5
* @param {String} nodeName name of the element
* @param {Document} ownerDocument The context document.
* @returns {Object} The shived element.
*/
function createElement(nodeName, ownerDocument, data) {
if (!ownerDocument) {
ownerDocument = document;
}
if (supportsUnknownElements) {
return ownerDocument.createElement(nodeName);
}
if (!data) {
data = getExpandoData(ownerDocument);
}
var node;
if (data.cache[nodeName]) {
node = data.cache[nodeName].cloneNode();
} else if (saveClones.test(nodeName)) {
node = (data.cache[nodeName] = data.createElem(nodeName)).cloneNode();
} else {
node = data.createElem(nodeName);
}
// Avoid adding some elements to fragments in IE < 9 because
// * Attributes like `name` or `type` cannot be set/changed once an element
// is inserted into a document/fragment
// * Link elements with `src` attributes that are inaccessible, as with
// a 403 response, will cause the tab/window to crash
// * Script elements appended to fragments will execute when their `src`
// or `text` property is set
return node.canHaveChildren && !reSkip.test(nodeName) && !node.tagUrn ? data.frag.appendChild(node) : node;
}
/**
* returns a shived DocumentFragment for the given document
* @memberOf html5
* @param {Document} ownerDocument The context document.
* @returns {Object} The shived DocumentFragment.
*/
function createDocumentFragment(ownerDocument, data) {
if (!ownerDocument) {
ownerDocument = document;
}
if (supportsUnknownElements) {
return ownerDocument.createDocumentFragment();
}
data = data || getExpandoData(ownerDocument);
var clone = data.frag.cloneNode(),
i = 0,
elems = getElements(),
l = elems.length;
for (; i < l; i++) {
clone.createElement(elems[i]);
}
return clone;
}
/**
* Shivs the `createElement` and `createDocumentFragment` methods of the document.
* @private
* @param {Document|DocumentFragment} ownerDocument The document.
* @param {Object} data of the document.
*/
function shivMethods(ownerDocument, data) {
if (!data.cache) {
data.cache = {};
data.createElem = ownerDocument.createElement;
data.createFrag = ownerDocument.createDocumentFragment;
data.frag = data.createFrag();
}
ownerDocument.createElement = function (nodeName) {
//abort shiv
if (!html5.shivMethods) {
return data.createElem(nodeName);
}
return createElement(nodeName, ownerDocument, data);
};
ownerDocument.createDocumentFragment = Function('h,f', 'return function(){' +
'var n=f.cloneNode(),c=n.createElement;' +
'h.shivMethods&&(' +
// unroll the `createElement` calls
getElements().join().replace(/[\w\-]+/g, function (nodeName) {
data.createElem(nodeName);
data.frag.createElement(nodeName);
return 'c("' + nodeName + '")';
}) +
');return n}'
)(html5, data.frag);
}
/*--------------------------------------------------------------------------*/
/**
* Shivs the given document.
* @memberOf html5
* @param {Document} ownerDocument The document to shiv.
* @returns {Document} The shived document.
*/
function shivDocument(ownerDocument) {
if (!ownerDocument) {
ownerDocument = document;
}
var data = getExpandoData(ownerDocument);
if (html5.shivCSS && !supportsHtml5Styles && !data.hasCSS) {
data.hasCSS = !!addStyleSheet(ownerDocument,
// corrects block display not defined in IE6/7/8/9
'article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}' +
// adds styling not present in IE6/7/8/9
'mark{background:#FF0;color:#000}' +
// hides non-rendered elements
'template{display:none}'
);
}
if (!supportsUnknownElements) {
shivMethods(ownerDocument, data);
}
return ownerDocument;
}
/*--------------------------------------------------------------------------*/
/**
* The `html5` object is exposed so that more elements can be shived and
* existing shiving can be detected on iframes.
* @type Object
* @example
*
* // options can be changed before the script is included
* html5 = { 'elements': 'mark section', 'shivCSS': false, 'shivMethods': false };
*/
var html5 = {
/**
* An array or space separated string of node names of the elements to shiv.
* @memberOf html5
* @type Array|String
*/
'elements': options.elements || 'abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video',
/**
* current version of html5shiv
*/
'version': version,
/**
* A flag to indicate that the HTML5 style sheet should be inserted.
* @memberOf html5
* @type Boolean
*/
'shivCSS': (options.shivCSS !== false),
/**
* Is equal to true if a browser supports creating unknown/HTML5 elements
* @memberOf html5
* @type boolean
*/
'supportsUnknownElements': supportsUnknownElements,
/**
* A flag to indicate that the document's `createElement` and `createDocumentFragment`
* methods should be overwritten.
* @memberOf html5
* @type Boolean
*/
'shivMethods': (options.shivMethods !== false),
/**
* A string to describe the type of `html5` object ("default" or "default print").
* @memberOf html5
* @type String
*/
'type': 'default',
// shivs the document according to the specified `html5` object options
'shivDocument': shivDocument,
//creates a shived element
createElement: createElement,
//creates a shived documentFragment
createDocumentFragment: createDocumentFragment
};
/*--------------------------------------------------------------------------*/
// expose html5
window.html5 = html5;
// shiv the document
shivDocument(document);
}(this, document));
/*>>shiv*/
// Assign private properties to the return object with prefix
Modernizr._version = version;
// expose these for the plugin API. Look in the source for how to join() them against your input
/*>>prefixes*/
Modernizr._prefixes = prefixes;
/*>>prefixes*/
/*>>domprefixes*/
Modernizr._domPrefixes = domPrefixes;
Modernizr._cssomPrefixes = cssomPrefixes;
/*>>domprefixes*/
/*>>mq*/
// Modernizr.mq tests a given media query, live against the current state of the window
// A few important notes:
// * If a browser does not support media queries at all (eg. oldIE) the mq() will always return false
// * A max-width or orientation query will be evaluated against the current state, which may change later.
// * You must specify values. Eg. If you are testing support for the min-width media query use:
// Modernizr.mq('(min-width:0)')
// usage:
// Modernizr.mq('only screen and (max-width:768)')
Modernizr.mq = testMediaQuery;
/*>>mq*/
/*>>hasevent*/
// Modernizr.hasEvent() detects support for a given event, with an optional element to test on
// Modernizr.hasEvent('gesturestart', elem)
Modernizr.hasEvent = isEventSupported;
/*>>hasevent*/
/*>>testprop*/
// Modernizr.testProp() investigates whether a given style property is recognized
// Note that the property names must be provided in the camelCase variant.
// Modernizr.testProp('pointerEvents')
Modernizr.testProp = function (prop) {
return testProps([prop]);
};
/*>>testprop*/
/*>>testallprops*/
// Modernizr.testAllProps() investigates whether a given style property,
// or any of its vendor-prefixed variants, is recognized
// Note that the property names must be provided in the camelCase variant.
// Modernizr.testAllProps('boxSizing')
Modernizr.testAllProps = testPropsAll;
/*>>testallprops*/
/*>>teststyles*/
// Modernizr.testStyles() allows you to add custom styles to the document and test an element afterwards
// Modernizr.testStyles('#modernizr { position:absolute }', function(elem, rule){ ... })
Modernizr.testStyles = injectElementWithStyles;
/*>>teststyles*/
/*>>prefixed*/
// Modernizr.prefixed() returns the prefixed or nonprefixed property name variant of your input
// Modernizr.prefixed('boxSizing') // 'MozBoxSizing'
// Properties must be passed as dom-style camelcase, rather than `box-sizing` hypentated style.
// Return values will also be the camelCase variant, if you need to translate that to hypenated style use:
//
// str.replace(/([A-Z])/g, function(str,m1){ return '-' + m1.toLowerCase(); }).replace(/^ms-/,'-ms-');
// If you're trying to ascertain which transition end event to bind to, you might do something like...
//
// var transEndEventNames = {
// 'WebkitTransition' : 'webkitTransitionEnd',
// 'MozTransition' : 'transitionend',
// 'OTransition' : 'oTransitionEnd',
// 'msTransition' : 'MSTransitionEnd',
// 'transition' : 'transitionend'
// },
// transEndEventName = transEndEventNames[ Modernizr.prefixed('transition') ];
Modernizr.prefixed = function (prop, obj, elem) {
if (!obj) {
return testPropsAll(prop, 'pfx');
} else {
// Testing DOM property e.g. Modernizr.prefixed('requestAnimationFrame', window) // 'mozRequestAnimationFrame'
return testPropsAll(prop, obj, elem);
}
};
/*>>prefixed*/
/*>>cssclasses*/
// Remove "no-js" class from element, if it exists:
docElement.className = docElement.className.replace(/(^|\s)no-js(\s|$)/, '$1$2') +
// Add the new classes to the element.
(enableClasses ? ' js ' + classes.join(' ') : '');
/*>>cssclasses*/
return Modernizr;
})(this, this.document);/**
* Theme functions file
*
* Contains handlers for navigation, accessibility, header sizing
* footer widgets and Featured Content slider
*
*/
( function( $ ) {
"use strict";
var _body = $( 'body' ),
_window = $( window );
$(document).ready(function() {
_filter_ajax_sort_count();
_sticky_menu();
_sticky_product();
_sticky_nextproduct();
_left_right_submenu();
_search_toggle();
_categories_menu_toggle();
_menu_categories();
_back_to_top();
_toggle_categories();
_event_single_image();
_load_wpbingo_menu_sidebar();
_event_ajax_search();
_event_circlestime();
_event_change_variation();
_event_accordion_slider();
_tongle_menu();
_remove_animation_tab_visua();
_event_video_product();
_event_lookbook();
_come_back();
_event_single_sticky_grid();
_load_video_popup();
_moreverticalMenu();
_click_button();
_tab_information_mobile();
_click_add_to_cart();
_after_add_to_cart();
_click_atribute_image();
_event_variable_thumb();
_update_total_wishlist();
_active_form_login();
_click_login_ajax();
_load_event_countdown();
_load_count_up();
_load_360_view_product();
_load_sale_nofication();
_ajax_cart_header();
_ajax_cart_page();
_load_slick_carousel($(".related .slick-carousel"));
_load_slick_carousel($(".recent-view .slick-carousel"));
_load_slick_carousel($(".post-related .slick-carousel"));
_load_slick_carousel($(".upsells .slick-carousel"));
_load_slick_carousel($(".cross_sell .slick-carousel"));
_load_slick_carousel($(".woocommerce-product-subcategories.slick-carousel"));
_load_slick_carousel($(".bestseller-product .slick-carousel"));
$(".gallery-slider .slick-carousel").each(function(){
_load_slick_carousel($(this));
});
$(".bwp-single-product .slick-carousel").each(function(){
_load_slick_carousel($(this));
$('.video-additional iframe').css("width",$(".image-additional #image").width());
$('.video-additional iframe').css("height",$(".image-additional #image").height());
$('.content-thumbnail-scroll .img-thumbnail-video img').css("width",$(".content-thumbnail-scroll .img-thumbnail-scroll img").width());
$('.content-thumbnail-scroll .img-thumbnail-video img').css("height",$(".content-thumbnail-scroll .img-thumbnail-scroll img").height());
});
_click_quickview_button();
_event_quick_buy();
});
$( document.body ).on( 'updated_cart_totals', function(){
_ajax_cart_page();
});
_window.resize(function() {
_load_canvas_menu();
_left_right_submenu();
_tongle_menu();
_moreverticalMenu();
});
/* Show/hide NewsLetter Popup */
_window.load(function() {
$("#loader").addClass("pre-loading");
_body.addClass('loaded');
});
function _load_sale_nofication(){
if($(".sale-nofication").length){
var $element = $('.sale-nofication');
var time_start = 0;
var start = $element.data('start');
time_start = start*1000;
$(".close-notification",$element).on( "click", function() {
if($element.hasClass('active')){
$element.removeClass('active');
}
});
setTimeout(function(){
_sale_nofication_start();
},time_start);
}
}
/* Come Back */
function _come_back(){
if( $('.come-back-alert').length > 0 ){
var title = $(document).attr("title");
var change_out2,change_out1;
var content1 = $('.come-back-alert').data('content1');
var content2 = $('.come-back-alert').data('content2');
document.addEventListener('visibilitychange', function (event) {
if (document.hidden) {
change_out2 = function () {
$(document).attr("title", content2);
setTimeout(function() {
change_out1();
}, 500);
};
change_out1 = function () {
$(document).attr("title", content1);
setTimeout(function() {
change_out2();
}, 500);
};
change_out1();
} else {
change_out1 = function () {};
change_out2 = function () {};
$(document).attr("title", title);
}
});
}
}
function _sale_nofication_start(){
}
function _update_total_wishlist(){
$(document).on( 'woosw_change_count', function(event, count){
var counter = $('.count-wishlist');
counter.html( count );
})
}
function _tongle_menu(){
var wd_width = _window.width();
var $menu_sidebar = $("#menu-main-menu",".home-sidebar");
//Menu Left
var $menu_left = $("#menu-main-menu",".header-v3");
appendGrower($menu_left);
//Menu Left Header 8
var $menu_left_2 = $("#menu-main-menu",".header-v8");
appendGrower($menu_left_2);
//Menu Left
if(wd_width > 991)
{
offtogglemegamenu($menu_sidebar);
}else{
appendGrower($menu_sidebar);
}
}
function _filter_ajax_sort_count(){
if(!$('.bwp-filter-ajax').length){
$( ".sort-count" ).on('change', function(){
var value = $(this).val();
_setGetParameter('product_count',value);
});
}
}
function _toggle_categories(){
var $root = $(".widget_product_categories");
if($(".current-cat-parent",$root).length > 0){
var $current_parent = $(".current-cat-parent",$root);
$current_parent.addClass('open');
$("> .children",$current_parent).stop().slideToggle(400);
}
var $current = $(".current-cat",$root);
$current.addClass('open');
$("> .children",$current).stop().slideToggle(400);
$( '.cat-parent',$root ).each(function(index) {
var $element = $(this);
if($(".children",$element).length > 0){
$element.prepend('');
$(".arrow",$element).on( 'click', function(e) {
e.preventDefault();
$element.toggleClass('open').find( '> .children' ).stop().slideToggle(400);
});
}
});
}
function _back_to_top(){
_window.scroll(function() {
if ($(this).scrollTop() > 800) {
$('.back-top').addClass('button-show');
}else {
$('.back-top').removeClass('button-show');
}
});
$('.back-top').on( "click", function() {
$('html, body').animate({
scrollTop: 0
}, 800);
return false;
});
}
function _categories_menu_toggle(){
if($('.categories-menu .btn-categories').length){
$('.categories-menu .btn-categories').on( "click", function(){
$('.wrapper-categories').toggleClass('bwp-active');
});
}
}
function _menu_categories(){
$('.main-menu-category .menu-lines').on( "click", function() {
if($('.main-category-menu').hasClass('active'))
$('.main-category-menu').removeClass('active');
else
$('.main-category-menu').addClass('active');
$('.close-menu-category').addClass('active');
return false;
});
$('.close-menu-category').on( "click", function() {
$('.main-category-menu').removeClass('active');
$(this).removeClass('active');
});
$('.main-category-menu .close-menu').on( "click", function() {
$('.main-category-menu').removeClass('active');
$('.close-menu-category').removeClass('active');
});
}
function _search_toggle(){
$( '.search-toggle' ).on( 'click.break', function( event ) {
$('.page-wrapper').toggleClass('opacity-style');
var wrapper = $( '.search-overlay' );
wrapper.toggleClass( 'search-visible' );
} );
$( '.close-search','.search-overlay' ).on( 'click.break', function( event ) {
$('.page-wrapper').toggleClass('opacity-style');
var wrapper = $( '.search-overlay' );
wrapper.toggleClass( 'search-visible');
} );
$( '.close-search','form.ajax-search' ).on( 'click', function( event ) {
var $parent = $(this).closest('.result-search-products-content');
$parent.css("display", "none");
$('.result-search-products',$parent).css("display", "none");
} );
}
function _show_homepage_sidebar(){
var $homepage_sidebar = $('.header-sideward-left-menu');
$('.btn-sideward-left').on( "click", function() {
if($homepage_sidebar.hasClass('active')){
$homepage_sidebar.removeClass('active');
}
else{
$homepage_sidebar.addClass('active');
}
return false;
});
}
_show_homepage_sidebar();
function _wpbingo_menu_left(){
//Navigation Right
var $header_wpbingo_menu_left = $('.header-wpbingo-menu-left');
$('.wpbingo-menu-left .menu-title').on( "click", function() {
if($header_wpbingo_menu_left.hasClass('active')){
$header_wpbingo_menu_left.removeClass('active');
}
else{
$header_wpbingo_menu_left.addClass('active');
}
return false;
});
}
_wpbingo_menu_left();
function _show_sticky_sidebar(){
var $sticky_sidebar = $('.sticky-sidebar');
$('.btn-sticky').on( "click", function() {
if($sticky_sidebar.hasClass('active')){
$sticky_sidebar.removeClass('active');
}
else{
$sticky_sidebar.addClass('active');
}
return false;
});
}
_show_sticky_sidebar();
function _mafoil_accordion_menu(){
var $elements = $(".categories-vertical-menu .widget-custom-menu");
$('.widget-title',$elements).on( "click", function() {
if($(this).hasClass('active')){
$(this).removeClass('active');
$('div',$(this).parent()).slideUp();
}
else{
$('.widget-title',$elements).removeClass('active');
$('div',$elements).slideUp();
$(this).addClass('active');
$('div',$(this).parent()).slideDown();
}
});
}
_mafoil_accordion_menu();
function _headercategories(){
//Navigation right
var $menu_categories = $('.menu-categories');
$('.navigation-categories').on( "click", function() {
if($menu_categories.hasClass('active')){
$menu_categories.removeClass('active');
}
else{
$menu_categories.addClass('active');
}
return false;
});
$('.mafoil-close',$menu_categories).on( "click", function() {
$menu_categories.removeClass('active');
return false;
});
//Navigation right
}
_headercategories();
function _canvasrightNavigation(){
//Navigation right
var $wpbingo_menu_right = $('.wpbingo-menu-right');
$('.navigation-right').on( "click", function() {
if($wpbingo_menu_right.hasClass('active')){
$wpbingo_menu_right.removeClass('active');
}
else{
$wpbingo_menu_right.addClass('active');
}
return false;
});
$('.mafoil-close',$wpbingo_menu_right).on( "click", function() {
$wpbingo_menu_right.removeClass('active');
return false;
});
//Navigation right
}
_canvasrightNavigation();
function _setGetParameter(paramName, paramValue)
{
var url = window.location.href;
var hash = location.hash;
url = url.replace(hash, '');
if (url.indexOf(paramName + "=") >= 0)
{
var prefix = url.substring(0, url.indexOf(paramName));
var suffix = url.substring(url.indexOf(paramName));
suffix = suffix.substring(suffix.indexOf("=") + 1);
suffix = (suffix.indexOf("&") >= 0) ? suffix.substring(suffix.indexOf("&")) : "";
url = prefix + paramName + "=" + paramValue + suffix;
}
else
{
if (url.indexOf("?") < 0)
url += "?" + paramName + "=" + paramValue;
else
url += "&" + paramName + "=" + paramValue;
}
window.location.href = url + hash;
}
function _sticky_menu(){
if($(".header-wrapper").data("sticky_header")){
var current_scroll = 0;
var bwp_width = _window.width();
_window.scroll(function() {
var next_scroll = $(this).scrollTop();
if ( next_scroll > 200) {
$('.bwp-header').addClass('sticky');
} else if ( next_scroll <=200 ) {
$('.bwp-header').removeClass('sticky');
}
current_scroll = next_scroll;
});
}
}
function _sticky_nextproduct(){
var $parent = $(".single-product");
if( $(".prev_next_buttons",$parent).length > 0 ){
var bwp_width = _window.width();
_window.scroll(function() {
var scroll_top = _window.scrollTop();
var offset_top = $(".woocommerce-tabs",$parent).offset().top;
var distance = (offset_top - scroll_top);
if ( distance <= 0) {
$('.prev_next_buttons',$parent).addClass('active');
}else{
$('.prev_next_buttons',$parent).removeClass('active');
}
});
}
}
function _sticky_product(){
var $parent = $(".single-product");
if( $(".sticky-product",$parent).length > 0 ){
var bwp_width = _window.width();
_window.scroll(function() {
var scroll_top = _window.scrollTop();
var offset_top = $(".single_add_to_cart_button",$parent).offset().top;
var distance = (offset_top - scroll_top);
if ( distance <= 0) {
$('.sticky-product',$parent).addClass('sticky');
}else{
$('.sticky-product',$parent).removeClass('sticky');
}
});
}
$('.select-cart-option').on( "click", function() {
$('html, body').animate({
scrollTop: 0
}, 800);
});
}
function _mafoil_top_link(){
var custom_menu = $('.block-top-link .widget-custom-menu');
$('.widget-title',custom_menu).on( "click", function(){
if($(this).hasClass('active')){
$(this).removeClass('active');
$('div',$(this).parent()).slideUp();
}
else{
$('.widget-title',custom_menu).removeClass('active');
$('div',custom_menu).slideUp();
$(this).addClass('active');
$('div',$(this).parent()).slideDown();
}
});
}
_mafoil_top_link();
function _load_slick_carousel($element,$move_nav=true){
$element.slick({
arrows: $element.data("nav") ? true : false ,
dots: $element.data("dots") ? true : false ,
draggable : $element.data("draggable") ? false : true ,
infinite: $element.data("infinite") ? false : true ,
autoplay: $element.data("autoplay") ? true : false ,
prevArrow: '',
slidesToScroll:$element.data("slidestoscroll") ? $element.data("columns") : 1,
nextArrow: '',
slidesToShow: $element.data("columns"),
asNavFor: $element.data("asnavfor") ? $element.data("asnavfor") : false ,
vertical: $element.data("vertical") ? true : false ,
verticalSwiping: $element.data("verticalswiping") ? $element.data("verticalswiping") : false ,
rtl: (_body.hasClass("rtl") && !$element.data("vertical")) ? true : false ,
centerMode: $element.data("centermode") ? $element.data("centermode") : false ,
centerPadding: $element.data("centerpadding") ? $element.data("centerpadding") : false ,
focusOnSelect: $element.data("focusonselect") ? $element.data("focusonselect") : false ,
fade: ($element.data("fade") && !_body.hasClass("rtl")) ? true : false ,
cssEase: 'linear',
autoplaySpeed: 5000,
pauseOnHover:true,
pauseOnFocus: false,
responsive: [
{
breakpoint: 1441,
settings: {
slidesToShow: $element.data("columns1440") ? $element.data("columns1440") : $element.data("columns"),
slidesToScroll: $element.data("columns1440") ? $element.data("columns1440") : $element.data("columns"),
}
},
{
breakpoint: 1200,
settings: {
slidesToShow: $element.data("columns1"),
slidesToScroll: $element.data("columns1"),
}
},
{
breakpoint: 1024,
settings: {
slidesToShow: $element.data("columns2"),
slidesToScroll: $element.data("columns2"),
}
},
{
breakpoint: 768,
settings: {
slidesToShow: $element.data("columns3"),
slidesToScroll: $element.data("columns3"),
vertical: false,
verticalSwiping : false,
}
},
{
breakpoint: 480,
settings: {
slidesToShow: $element.data("columns4"),
slidesToScroll: $element.data("columns4"),
vertical: false,
verticalSwiping : false,
}
}
]
});
var $single_product = $(".bwp-single-product");
$element.on('afterChange', function(event, slick, currentSlide, nextSlide){
_move_nav_slick($element);
if($single_product.length > 0 && $single_product.hasClass("zoom") ){
var _data = $single_product.data();
if(_data.product_layout_thumb != "one_column" && _data.product_layout_thumb != "grid" && _data.product_layout_thumb != "two_column" && _data.product_layout_thumb != "grid_sticky" ){
$('.zoomContainer').remove();
var _data = $single_product.data();
var $image_thumbnail = $(".img-thumbnail.slick-current",".main-single-product .image-additional");
if (($(window).width()) >= 768 ){
_load_zoom_single_inner($("img",$image_thumbnail),_data);
}
}
}
});
_move_nav_slick($element);
if($single_product.length > 0 && $single_product.hasClass("zoom") ){
var _data = $single_product.data();
var $image_thumbnail = $(".img-thumbnail.slick-current",".image-additional");
if (($(window).width()) >= 768 ){
_load_zoom_single_inner($("img",$image_thumbnail),_data);
}
}
}
function _move_nav_slick($element){
if($(".slick-arrow",$element).length > 0){
if( $(".fa-angle-left",$element).length > 0 ){
var $prev = $(".fa-angle-left",$element).clone();
$(".fa-angle-left",$element).remove();
if($element.parent().find(".fa-angle-left").length == 0){
$prev.prependTo($element.parent());
}
$prev.on( "click", function() {
$element.slick('slickPrev');
});
}
if( $(".fa-angle-right",$element).length > 0 ){
var $next = $(".fa-angle-right",$element).clone();
$(".fa-angle-right",$element).remove();
if($element.parent().find(".fa-angle-right").length == 0){
$next.appendTo($element.parent());
}
$next.on( "click", function() {
$element.slick('slickNext');
});
}
}
}
//Dropdown Menu
function _dropdown_menu(){
$( ".pwb-dropdown" ).each(function(){
var $dropdown = $(this);
var active_text = $dropdown.find('li.active').text();
if(active_text){
$(".pwb-dropdown-toggle",$dropdown).html(active_text);
}
$("li",$dropdown).on( "click", function() {
$("li",$dropdown).removeClass("active");
$(this).addClass('active');
var this_text = $(this).text();
$(".pwb-dropdown-toggle",$dropdown).html(this_text);
$dropdown.removeClass("open");
if($dropdown.hasClass('select_category')){
var this_value = $(this).data("value");
$( ".product-cat",".select_category" ).val(this_value);
}
});
});
}
_dropdown_menu();
function _click_toggle_filter(){
$(".button-filter-toggle").on( "click", function() {
if($(this).hasClass('active')){
$(".button-filter-toggle").removeClass('active');
$(".filter_sideout").removeClass('active');
$(".sidebar-product-filter").removeClass('active');
$(".main-archive-product").removeClass('active');
$(".remove-sidebar").removeClass('active');
$(".sidebar-product-filter").slideUp();
}else{
$(".button-filter-toggle").addClass('active');
$(".filter_sideout").addClass('active');
$(".sidebar-product-filter").addClass('active');
$(".main-archive-product").addClass('active');
$(".remove-sidebar").addClass('active');
$(".sidebar-product-filter").slideDown();
}
});
$(".remove-sidebar").on( "click", function() {
$(this).removeClass('active');
$(".main-archive-product").removeClass('active');
$(".sidebar-product-filter").removeClass('active');
$(".button-filter-toggle").removeClass('active');
});
}
_click_toggle_filter();
//Menu CanVas
function _click_button_canvas_menu(){
$('#show-megamenu').on( "click", function() {
if($('.content-mobile-menu').hasClass('active'))
$('.content-mobile-menu').removeClass('active');
else
$('.content-mobile-menu').addClass('active');
return false;
});
$('#show-megamenu').on( "click", function() {
if($('.remove-mobile-menu').hasClass('active'))
$('.remove-mobile-menu').removeClass('active');
else
$('.remove-mobile-menu').addClass('active');
return false;
});
$('.remove-mobile-menu').on( "click", function() {
$(this).removeClass('active');
$('.content-mobile-menu').removeClass('active');
});
$('#show-verticalmenu').on( "click", function() {
if( $(".bwp-canvas-vertical").hasClass('active')){
$(".bwp-canvas-vertical").removeClass('active');
}
else{
$(".bwp-canvas-vertical").addClass('active');
}
return false;
});
}
_click_button_canvas_menu();
function _load_canvas_menu(){
var wd_width = _window.width();
var $main_menu = $(".menu","#main-navigation");
if(wd_width <= 991){
if($("#canvas-main-menu").length < 1 && $main_menu.length > 0){
var $menu = $main_menu.parent().clone();
$menu.attr( "id", "canvas-main-menu");
$($menu).find(".menu").removeAttr('id');
$('.content-mobile-menu').prepend('