"
},
k = function(t, e, o) {
var i = new Date(o, 0, 1),
n = Math.ceil(((new Date(o, e, t) - i) / 864e5 + i.getDay() + 1) / 7);
return '
' + n + "
"
},
C = function(t, e) {
return "
" + (e ? t.reverse() : t).join("") + "
"
},
L = function(t) {
return "" + t.join("") + ""
},
S = function(t) {
var e, o = [];
for (t.showWeekNumber && o.push("
"), e = 0; e < 7; e++) o.push('
' + T(t, e, !0) + "
");
return "
" + (t.isRTL ? o.reverse() : o).join("") + "
"
},
E = function(t, e, o, i, n, s) {
var r, a, l, h, d, c = t._o,
u = o === c.minYear,
f = o === c.maxYear,
m = '
',
g = !0,
v = !0;
for (l = [], r = 0; r < 12; r++) l.push('");
for (h = '
' + c.i18n.months[i] + '
", p(c.yearRange) ? (r = c.yearRange[0], a = c.yearRange[1] + 1) : (r = o - c.yearRange, a = 1 + o + c.yearRange), l = []; r < a && r <= c.maxYear; r++) r >= c.minYear && l.push('");
return d = '
' + o + c.yearSuffix + '
", m += c.showMonthAfterYear ? d + h : h + d, u && (0 === i || c.minMonth >= i) && (g = !1), f && (11 === i || c.maxMonth <= i) && (v = !1), 0 === e && (m += '"), e === t._o.numberOfMonths - 1 && (m += '"), m += "
"
},
W = function(t, e, o) {
return '
' + S(t) + L(e) + "
"
},
O = function(r) {
var a = this,
l = a.config(r);
a._onMouseDown = function(t) {
if (a._v) {
t = t || window.event;
var e = t.target || t.srcElement;
if (e)
if (h(e, "is-disabled") || (!h(e, "pika-button") || h(e, "is-empty") || h(e.parentNode, "is-disabled") ? h(e, "pika-prev") ? a.prevMonth() : h(e, "pika-next") && a.nextMonth() : (a.setDate(new Date(e.getAttribute("data-pika-year"), e.getAttribute("data-pika-month"), e.getAttribute("data-pika-day"))), l.bound && n(function() {
a.hide(), l.field && l.field.blur()
}, 100))), h(e, "pika-select")) a._c = !0;
else {
if (!t.preventDefault) return t.returnValue = !1, !1;
t.preventDefault()
}
}
}, a._onChange = function(t) {
t = t || window.event;
var e = t.target || t.srcElement;
e && (h(e, "pika-select-month") ? a.gotoMonth(e.value) : h(e, "pika-select-year") && a.gotoYear(e.value))
}, a._onKeyChange = function(t) {
if (t = t || window.event, a.isVisible()) switch (t.keyCode) {
case 13:
case 27:
l.field.blur();
break;
case 37:
t.preventDefault(), a.adjustDate("subtract", 1);
break;
case 38:
a.adjustDate("subtract", 7);
break;
case 39:
a.adjustDate("add", 1);
break;
case 40:
a.adjustDate("add", 7)
}
}, a._onInputChange = function(o) {
var i;
o.firedBy !== a && (e ? (i = t(l.field.value, l.format, l.formatStrict), i = i && i.isValid() ? i.toDate() : null) : i = new Date(Date.parse(l.field.value)), u(i) && a.setDate(i), a._v || a.show())
}, a._onInputFocus = function() {
a.show()
}, a._onInputClick = function() {
a.show()
}, a._onInputBlur = function() {
var t = i.activeElement;
do
if (h(t, "pika-single")) return;
while (t = t.parentNode);
a._c || (a._b = n(function() {
a.hide()
}, 50)), a._c = !1
}, a._onClick = function(t) {
t = t || window.event;
var e = t.target || t.srcElement,
i = e;
if (e) {
!o && h(e, "pika-select") && (e.onchange || (e.setAttribute("onchange", "return;"), s(e, "change", a._onChange)));
do
if (h(i, "pika-single") || i === l.trigger) return;
while (i = i.parentNode);
a._v && e !== l.trigger && i !== l.trigger && a.hide()
}
}, a.el = i.createElement("div"), a.el.className = "pika-single" + (l.isRTL ? " is-rtl" : "") + (l.theme ? " " + l.theme : ""), s(a.el, "mousedown", a._onMouseDown, !0), s(a.el, "touchend", a._onMouseDown, !0), s(a.el, "change", a._onChange), s(i, "keydown", a._onKeyChange), l.field && (l.container ? l.container.appendChild(a.el) : l.bound ? i.body.appendChild(a.el) : l.field.parentNode.insertBefore(a.el, l.field.nextSibling), s(l.field, "change", a._onInputChange), l.defaultDate || (e && l.field.value ? l.defaultDate = t(l.field.value, l.format).toDate() : l.defaultDate = new Date(Date.parse(l.field.value)), l.setDefaultDate = !0));
var d = l.defaultDate;
u(d) ? l.setDefaultDate ? a.setDate(d, !0) : a.gotoDate(d) : a.gotoDate(new Date), l.bound ? (this.hide(), a.el.className += " is-bound", s(l.trigger, "click", a._onInputClick), s(l.trigger, "focus", a._onInputFocus), s(l.trigger, "blur", a._onInputBlur)) : this.show()
};
return O.prototype = {
config: function(t) {
this._o || (this._o = w({}, z, !0));
var e = w(this._o, t, !0);
e.isRTL = !!e.isRTL, e.field = e.field && e.field.nodeName ? e.field : null, e.theme = "string" == typeof e.theme && e.theme ? e.theme : null, e.bound = !!(void 0 !== e.bound ? e.field && e.bound : e.field), e.trigger = e.trigger && e.trigger.nodeName ? e.trigger : e.field, e.disableWeekends = !!e.disableWeekends, e.disableDayFn = "function" == typeof e.disableDayFn ? e.disableDayFn : null;
var o = parseInt(e.numberOfMonths, 10) || 1;
if (e.numberOfMonths = o > 4 ? 4 : o, u(e.minDate) || (e.minDate = !1), u(e.maxDate) || (e.maxDate = !1), e.minDate && e.maxDate && e.maxDate < e.minDate && (e.maxDate = e.minDate = !1), e.minDate && this.setMinDate(e.minDate), e.maxDate && this.setMaxDate(e.maxDate), p(e.yearRange)) {
var i = (new Date).getFullYear() - 10;
e.yearRange[0] = parseInt(e.yearRange[0], 10) || i, e.yearRange[1] = parseInt(e.yearRange[1], 10) || i
} else e.yearRange = Math.abs(parseInt(e.yearRange, 10)) || z.yearRange, e.yearRange > 100 && (e.yearRange = 100);
return e
},
toString: function(o) {
return u(this._d) ? e ? t(this._d).format(o || this._o.format) : this._d.toDateString() : ""
},
getMoment: function() {
return e ? t(this._d) : null
},
setMoment: function(o, i) {
e && t.isMoment(o) && this.setDate(o.toDate(), i)
},
getDate: function() {
return u(this._d) ? new Date(this._d.getTime()) : new Date
},
setDate: function(t, e) {
if (!t) return this._d = null, this._o.field && (this._o.field.value = "", a(this._o.field, "change", {
firedBy: this
})), this.draw();
if ("string" == typeof t && (t = new Date(Date.parse(t))), u(t)) {
var o = this._o.minDate,
i = this._o.maxDate;
u(o) && t < o ? t = o : u(i) && t > i && (t = i), this._d = new Date(t.getTime()), v(this._d), this.gotoDate(this._d), this._o.field && (this._o.field.value = this.toString(), a(this._o.field, "change", {
firedBy: this
})), e || "function" != typeof this._o.onSelect || this._o.onSelect.call(this, this.getDate())
}
},
gotoDate: function(t) {
var e = !0;
if (u(t)) {
if (this.calendars) {
var o = new Date(this.calendars[0].year, this.calendars[0].month, 1),
i = new Date(this.calendars[this.calendars.length - 1].year, this.calendars[this.calendars.length - 1].month, 1),
n = t.getTime();
i.setMonth(i.getMonth() + 1), i.setDate(i.getDate() - 1), e = n < o.getTime() || i.getTime() < n
}
e && (this.calendars = [{
month: t.getMonth(),
year: t.getFullYear()
}], "right" === this._o.mainCalendar && (this.calendars[0].month += 1 - this._o.numberOfMonths)), this.adjustCalendars()
}
},
adjustDate: function(o, i) {
var n, s = this.getDate(),
r = 24 * parseInt(i) * 60 * 60 * 1e3;
"add" === o ? n = new Date(s.valueOf() + r) : "subtract" === o && (n = new Date(s.valueOf() - r)), e && ("add" === o ? n = t(s).add(i, "days").toDate() : "subtract" === o && (n = t(s).subtract(i, "days").toDate())), this.setDate(n)
},
adjustCalendars: function() {
this.calendars[0] = b(this.calendars[0]);
for (var t = 1; t < this._o.numberOfMonths; t++) this.calendars[t] = b({
month: this.calendars[0].month + t,
year: this.calendars[0].year
});
this.draw()
},
gotoToday: function() {
this.gotoDate(new Date)
},
gotoMonth: function(t) {
isNaN(t) || (this.calendars[0].month = parseInt(t, 10), this.adjustCalendars())
},
nextMonth: function() {
this.calendars[0].month++, this.adjustCalendars()
},
prevMonth: function() {
this.calendars[0].month--, this.adjustCalendars()
},
gotoYear: function(t) {
isNaN(t) || (this.calendars[0].year = parseInt(t, 10), this.adjustCalendars())
},
setMinDate: function(t) {
t instanceof Date ? (v(t), this._o.minDate = t, this._o.minYear = t.getFullYear(), this._o.minMonth = t.getMonth()) : (this._o.minDate = z.minDate, this._o.minYear = z.minYear, this._o.minMonth = z.minMonth, this._o.startRange = z.startRange), this.draw()
},
setMaxDate: function(t) {
t instanceof Date ? (v(t), this._o.maxDate = t, this._o.maxYear = t.getFullYear(), this._o.maxMonth = t.getMonth()) : (this._o.maxDate = z.maxDate, this._o.maxYear = z.maxYear, this._o.maxMonth = z.maxMonth, this._o.endRange = z.endRange), this.draw()
},
setStartRange: function(t) {
this._o.startRange = t
},
setEndRange: function(t) {
this._o.endRange = t
},
draw: function(t) {
if (this._v || t) {
var e, o = this._o,
i = o.minYear,
s = o.maxYear,
r = o.minMonth,
a = o.maxMonth,
l = "";
this._y <= i && (this._y = i, !isNaN(r) && this._m < r && (this._m = r)), this._y >= s && (this._y = s, !isNaN(a) && this._m > a && (this._m = a)), e = "pika-title-" + Math.random().toString(36).replace(/[^a-z]+/g, "").substr(0, 2);
for (var h = 0; h < o.numberOfMonths; h++) l += '
";
this.el.innerHTML = l, o.bound && "hidden" !== o.field.type && n(function() {
o.trigger.focus()
}, 1), "function" == typeof this._o.onDraw && this._o.onDraw(this), o.bound && o.field.setAttribute("aria-label", "Use the arrow keys to pick a date")
}
},
adjustPosition: function() {
var t, e, o, n, s, r, a, l, h, d;
if (!this._o.container) {
if (this.el.style.position = "absolute", t = this._o.trigger, e = t, o = this.el.offsetWidth, n = this.el.offsetHeight, s = window.innerWidth || i.documentElement.clientWidth, r = window.innerHeight || i.documentElement.clientHeight, a = window.pageYOffset || i.body.scrollTop || i.documentElement.scrollTop, "function" == typeof t.getBoundingClientRect) d = t.getBoundingClientRect(), l = d.left + window.pageXOffset, h = d.bottom + window.pageYOffset;
else
for (l = e.offsetLeft, h = e.offsetTop + e.offsetHeight; e = e.offsetParent;) l += e.offsetLeft, h += e.offsetTop;
(this._o.reposition && l + o > s || this._o.position.indexOf("right") > -1 && l - o + t.offsetWidth > 0) && (l = l - o + t.offsetWidth), (this._o.reposition && h + n > r + a || this._o.position.indexOf("top") > -1 && h - n - t.offsetHeight > 0) && (h = h - n - t.offsetHeight), this.el.style.left = l + "px", this.el.style.top = h + "px"
}
},
render: function(t, e, o) {
var i = this._o,
n = new Date,
s = g(t, e),
r = new Date(t, e, 1).getDay(),
a = [],
l = [];
v(n), i.firstDay > 0 && (r -= i.firstDay, r < 0 && (r += 7));
for (var h = 0 === e ? 11 : e - 1, d = 11 === e ? 0 : e + 1, c = 0 === e ? t - 1 : t, p = 11 === e ? t + 1 : t, m = g(c, h), w = s + r, b = w; b > 7;) b -= 7;
w += 7 - b;
for (var z = 0, T = 0; z < w; z++) {
var L = new Date(t, e, 1 + (z - r)),
S = !!u(this._d) && y(L, this._d),
E = y(L, n),
O = z < r || z >= s + r,
_ = 1 + (z - r),
I = e,
P = t,
$ = i.startRange && y(i.startRange, L),
D = i.endRange && y(i.endRange, L),
M = i.startRange && i.endRange && i.startRange < L && L < i.endRange,
R = i.minDate && L < i.minDate || i.maxDate && L > i.maxDate || i.disableWeekends && f(L) || i.disableDayFn && i.disableDayFn(L);
O && (z < r ? (_ = m + _, I = h, P = c) : (_ -= s, I = d, P = p));
var A = {
day: _,
month: I,
year: P,
isSelected: S,
isToday: E,
isDisabled: R,
isEmpty: O,
isStartRange: $,
isEndRange: D,
isInRange: M,
showDaysInNextAndPreviousMonths: i.showDaysInNextAndPreviousMonths
};
l.push(x(A)), 7 === ++T && (i.showWeekNumber && l.unshift(k(z - r, e, t)), a.push(C(l, i.isRTL)), l = [], T = 0)
}
return W(i, a, o)
},
isVisible: function() {
return this._v
},
show: function() {
this.isVisible() || (c(this.el, "is-hidden"), this._v = !0, this.draw(), this._o.bound && (s(i, "click", this._onClick), this.adjustPosition()), "function" == typeof this._o.onOpen && this._o.onOpen.call(this))
},
hide: function() {
var t = this._v;
t !== !1 && (this._o.bound && r(i, "click", this._onClick), this.el.style.position = "static", this.el.style.left = "auto", this.el.style.top = "auto", d(this.el, "is-hidden"), this._v = !1, void 0 !== t && "function" == typeof this._o.onClose && this._o.onClose.call(this))
},
destroy: function() {
this.hide(), r(this.el, "mousedown", this._onMouseDown, !0), r(this.el, "touchend", this._onMouseDown, !0), r(this.el, "change", this._onChange), this._o.field && (r(this._o.field, "change", this._onInputChange), this._o.bound && (r(this._o.trigger, "click", this._onInputClick), r(this._o.trigger, "focus", this._onInputFocus), r(this._o.trigger, "blur", this._onInputBlur))), this.el.parentNode && this.el.parentNode.removeChild(this.el)
}
}, O
}), document.addEventListener("DOMContentLoaded", function() {
var t = function() {
if ("scrollingElement" in document) return document.scrollingElement;
var t = document.documentElement,
e = t.scrollTop;
t.scrollTop = e + 1;
var o = t.scrollTop;
return t.scrollTop = e, o > e ? t : document.body
}(),
e = function(e) {
var o = t.scrollTop;
if (2 > e.length) e = -o;
else if (e = document.querySelector(e)) {
e = e.getBoundingClientRect().top;
var i = t.scrollHeight - window.innerHeight;
e = o + e < i ? e : i - o
} else e = void 0;
if (e) return new Map([
["start", o],
["delta", e]
])
},
o = function(o) {
var i = o.getAttribute("href"),
n = e(i);
if (n) {
var s = new Map([
["duration", 800]
]),
r = performance.now();
requestAnimationFrame(function e(o) {
s.set("elapsed", o - r), o = s.get("duration");
var a = s.get("elapsed"),
l = n.get("start"),
h = n.get("delta");
t.scrollTop = Math.round(h * (-Math.pow(2, -10 * a / o) + 1) + l), s.get("elapsed") < s.get("duration") ? requestAnimationFrame(e) : (history.pushState(null, null, i), t.scrollTop = n.get("start") + n.get("delta"))
})
}
},
i = function t(e, i) {
var n = e.item(i);
if (n.addEventListener("click", function(t) {
t.preventDefault(), o(n)
}), i) return t(e, i - 1)
},
n = document.querySelectorAll("a.scroll"),
s = n.length - 1;
0 > s || i(n, s)
}), ! function(t, e, o) {
"use strict";
function i(o) {
if (n = e.documentElement, s = e.body, U(), at = this, o = o || {}, pt = o.constants || {}, o.easing)
for (var i in o.easing) V[i] = o.easing[i];
wt = o.edgeStrategy || "set", dt = {
beforerender: o.beforerender,
render: o.render,
keyframe: o.keyframe
}, ct = o.forceHeight !== !1, ct && (Mt = o.scale || 1), ut = o.mobileDeceleration || k, mt = o.smoothScrolling !== !1, gt = o.smoothScrollingDuration || L, vt = {
targetTop: at.getScrollTop()
}, Yt = (o.mobileCheck || function() {
return /Android|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent || navigator.vendor || t.opera)
})(), Yt ? (ht = e.getElementById(o.skrollrBody || C), ht && rt(), X(), Ot(n, [y, z], [w])) : Ot(n, [y, b], [w]), at.refresh(), Tt(t, "resize orientationchange", function() {
var t = n.clientWidth,
e = n.clientHeight;
(e !== jt || t !== Nt) && (jt = e, Nt = t, Bt = !0)
});
var r = q();
return function t() {
K(), zt = r(t)
}(), at
}
var n, s, r = {
get: function() {
return at
},
init: function(t) {
return at || new i(t)
},
VERSION: "0.6.30"
},
a = Object.prototype.hasOwnProperty,
l = t.Math,
h = t.getComputedStyle,
d = "touchstart",
c = "touchmove",
p = "touchcancel",
u = "touchend",
f = "skrollable",
m = f + "-before",
g = f + "-between",
v = f + "-after",
y = "skrollr",
w = "no-" + y,
b = y + "-desktop",
z = y + "-mobile",
T = "linear",
x = 1e3,
k = .004,
C = "skrollr-body",
L = 200,
S = "start",
E = "end",
W = "center",
O = "bottom",
_ = "___skrollable_id",
I = /^(?:input|textarea|button|select)$/i,
P = /^\s+|\s+$/g,
$ = /^data(?:-(_\w+))?(?:-?(-?\d*\.?\d+p?))?(?:-?(start|end|top|center|bottom))?(?:-?(top|center|bottom))?$/,
D = /\s*(@?[\w\-\[\]]+)\s*:\s*(.+?)\s*(?:;|$)/gi,
M = /^(@?[a-z\-]+)\[(\w+)\]$/,
R = /-([a-z0-9_])/g,
A = function(t, e) {
return e.toUpperCase()
},
H = /[\-+]?[\d]*\.?[\d]+/g,
N = /\{\?\}/g,
j = /rgba?\(\s*-?\d+\s*,\s*-?\d+\s*,\s*-?\d+/g,
B = /[a-z\-]+-gradient/g,
F = "",
Y = "",
U = function() {
var t = /^(?:O|Moz|webkit|ms)|(?:-(?:o|moz|webkit|ms)-)/;
if (h) {
var e = h(s, null);
for (var o in e)
if (F = o.match(t) || +o == o && e[o].match(t)) break;
if (!F) return void(F = Y = "");
F = F[0], "-" === F.slice(0, 1) ? (Y = F, F = {
"-webkit-": "webkit",
"-moz-": "Moz",
"-ms-": "ms",
"-o-": "O"
}[F]) : Y = "-" + F.toLowerCase() + "-"
}
},
q = function() {
var e = t.requestAnimationFrame || t[F.toLowerCase() + "RequestAnimationFrame"],
o = Pt();
return (Yt || !e) && (e = function(e) {
var i = Pt() - o,
n = l.max(0, 1e3 / 60 - i);
return t.setTimeout(function() {
o = Pt(), e()
}, n)
}), e
},
Z = function() {
var e = t.cancelAnimationFrame || t[F.toLowerCase() + "CancelAnimationFrame"];
return (Yt || !e) && (e = function(e) {
return t.clearTimeout(e)
}), e
},
V = {
begin: function() {
return 0
},
end: function() {
return 1
},
linear: function(t) {
return t
},
quadratic: function(t) {
return t * t
},
cubic: function(t) {
return t * t * t
},
swing: function(t) {
return -l.cos(t * l.PI) / 2 + .5
},
sqrt: function(t) {
return l.sqrt(t)
},
outCubic: function(t) {
return l.pow(t - 1, 3) + 1
},
bounce: function(t) {
var e;
if (.5083 >= t) e = 3;
else if (.8489 >= t) e = 9;
else if (.96208 >= t) e = 27;
else {
if (!(.99981 >= t)) return 1;
e = 91
}
return 1 - l.abs(3 * l.cos(t * e * 1.028) / e)
}
};
i.prototype.refresh = function(t) {
var i, n, s = !1;
for (t === o ? (s = !0, lt = [], Ft = 0, t = e.getElementsByTagName("*")) : t.length === o && (t = [t]), i = 0, n = t.length; n > i; i++) {
var r = t[i],
a = r,
l = [],
h = mt,
d = wt,
c = !1;
if (s && _ in r && delete r[_], r.attributes) {
for (var p = 0, u = r.attributes.length; u > p; p++) {
var m = r.attributes[p];
if ("data-anchor-target" !== m.name)
if ("data-smooth-scrolling" !== m.name)
if ("data-edge-strategy" !== m.name)
if ("data-emit-events" !== m.name) {
var g = m.name.match($);
if (null !== g) {
var v = {
props: m.value,
element: r,
eventType: m.name.replace(R, A)
};
l.push(v);
var y = g[1];
y && (v.constant = y.substr(1));
var w = g[2];
/p$/.test(w) ? (v.isPercentage = !0, v.offset = (0 | w.slice(0, -1)) / 100) : v.offset = 0 | w;
var b = g[3],
z = g[4] || b;
b && b !== S && b !== E ? (v.mode = "relative", v.anchors = [b, z]) : (v.mode = "absolute", b === E ? v.isEnd = !0 : v.isPercentage || (v.offset = v.offset * Mt))
}
} else c = !0;
else d = m.value;
else h = "off" !== m.value;
else if (a = e.querySelector(m.value), null === a) throw 'Unable to find anchor target "' + m.value + '"'
}
if (l.length) {
var T, x, k;
!s && _ in r ? (k = r[_], T = lt[k].styleAttr, x = lt[k].classAttr) : (k = r[_] = Ft++, T = r.style.cssText, x = Wt(r)), lt[k] = {
element: r,
styleAttr: T,
classAttr: x,
anchorTarget: a,
keyFrames: l,
smoothScrolling: h,
edgeStrategy: d,
emitEvents: c,
lastFrameIndex: -1
}, Ot(r, [f], [])
}
}
}
for (Lt(), i = 0, n = t.length; n > i; i++) {
var C = lt[t[i][_]];
C !== o && (J(C), et(C))
}
return at
}, i.prototype.relativeToAbsolute = function(t, e, o) {
var i = n.clientHeight,
s = t.getBoundingClientRect(),
r = s.top,
a = s.bottom - s.top;
return e === O ? r -= i : e === W && (r -= i / 2), o === O ? r += a : o === W && (r += a / 2), r += at.getScrollTop(), r + .5 | 0
}, i.prototype.animateTo = function(t, e) {
e = e || {};
var i = Pt(),
n = at.getScrollTop(),
s = e.duration === o ? x : e.duration;
return ft = {
startTop: n,
topDiff: t - n,
targetTop: t,
duration: s,
startTime: i,
endTime: i + s,
easing: V[e.easing || T],
done: e.done
}, ft.topDiff || (ft.done && ft.done.call(at, !1), ft = o), at
}, i.prototype.stopAnimateTo = function() {
ft && ft.done && ft.done.call(at, !0), ft = o
}, i.prototype.isAnimatingTo = function() {
return !!ft
}, i.prototype.isMobile = function() {
return Yt
}, i.prototype.setScrollTop = function(e, o) {
return yt = o === !0, Yt ? Ut = l.min(l.max(e, 0), Dt) : t.scrollTo(0, e), at
}, i.prototype.getScrollTop = function() {
return Yt ? Ut : t.pageYOffset || n.scrollTop || s.scrollTop || 0
}, i.prototype.getMaxScrollTop = function() {
return Dt
}, i.prototype.on = function(t, e) {
return dt[t] = e, at
}, i.prototype.off = function(t) {
return delete dt[t], at
}, i.prototype.destroy = function() {
var t = Z();
t(zt), kt(), Ot(n, [w], [y, b, z]);
for (var e = 0, i = lt.length; i > e; e++) st(lt[e].element);
n.style.overflow = s.style.overflow = "", n.style.height = s.style.height = "", ht && r.setStyle(ht, "transform", "none"), at = o, ht = o, dt = o, ct = o, Dt = 0, Mt = 1, pt = o, ut = o, Rt = "down", At = -1, Nt = 0, jt = 0, Bt = !1, ft = o, mt = o, gt = o, vt = o, yt = o, Ft = 0, wt = o, Yt = !1, Ut = 0, bt = o
};
var X = function() {
var i, r, a, h, f, m, g, v, y, w, b, z;
Tt(n, [d, c, p, u].join(" "), function(t) {
var n = t.changedTouches[0];
for (h = t.target; 3 === h.nodeType;) h = h.parentNode;
switch (f = n.clientY, m = n.clientX, w = t.timeStamp, I.test(h.tagName) || t.preventDefault(), t.type) {
case d:
i && i.blur(), at.stopAnimateTo(), i = h, r = g = f, a = m, y = w;
break;
case c:
I.test(h.tagName) && e.activeElement !== h && t.preventDefault(), v = f - g, z = w - b, at.setScrollTop(Ut - v, !0), g = f, b = w;
break;
default:
case p:
case u:
var s = r - f,
T = a - m,
x = T * T + s * s;
if (49 > x) {
if (!I.test(i.tagName)) {
i.focus();
var k = e.createEvent("MouseEvents");
k.initMouseEvent("click", !0, !0, t.view, 1, n.screenX, n.screenY, n.clientX, n.clientY, t.ctrlKey, t.altKey, t.shiftKey, t.metaKey, 0, null), i.dispatchEvent(k)
}
return
}
i = o;
var C = v / z;
C = l.max(l.min(C, 3), -3);
var L = l.abs(C / ut),
S = C * L + .5 * ut * L * L,
E = at.getScrollTop() - S,
W = 0;
E > Dt ? (W = (Dt - E) / S, E = Dt) : 0 > E && (W = -E / S, E = 0), L *= 1 - W, at.animateTo(E + .5 | 0, {
easing: "outCubic",
duration: L
})
}
}), t.scrollTo(0, 0), n.style.overflow = s.style.overflow = "hidden"
},
G = function() {
var t, e, o, i, s, r, a, h, d, c, p, u = n.clientHeight,
f = St();
for (h = 0, d = lt.length; d > h; h++)
for (t = lt[h], e = t.element, o = t.anchorTarget, i = t.keyFrames, s = 0, r = i.length; r > s; s++) a = i[s], c = a.offset, p = f[a.constant] || 0, a.frame = c, a.isPercentage && (c *= u, a.frame = c), "relative" === a.mode && (st(e), a.frame = at.relativeToAbsolute(o, a.anchors[0], a.anchors[1]) - c, st(e, !0)), a.frame += p, ct && !a.isEnd && a.frame > Dt && (Dt = a.frame);
for (Dt = l.max(Dt, Et()), h = 0, d = lt.length; d > h; h++) {
for (t = lt[h], i = t.keyFrames, s = 0, r = i.length; r > s; s++) a = i[s], p = f[a.constant] || 0, a.isEnd && (a.frame = Dt - a.offset + p);
t.keyFrames.sort($t)
}
},
Q = function(t, e) {
for (var o = 0, i = lt.length; i > o; o++) {
var n, s, l = lt[o],
h = l.element,
d = l.smoothScrolling ? t : e,
c = l.keyFrames,
p = c.length,
u = c[0],
y = c[c.length - 1],
w = d < u.frame,
b = d > y.frame,
z = w ? u : y,
T = l.emitEvents,
x = l.lastFrameIndex;
if (w || b) {
if (w && -1 === l.edge || b && 1 === l.edge) continue;
switch (w ? (Ot(h, [m], [v, g]), T && x > -1 && (Ct(h, u.eventType, Rt), l.lastFrameIndex = -1)) : (Ot(h, [v], [m, g]), T && p > x && (Ct(h, y.eventType, Rt), l.lastFrameIndex = p)), l.edge = w ? -1 : 1, l.edgeStrategy) {
case "reset":
st(h);
continue;
case "ease":
d = z.frame;
break;
default:
case "set":
var k = z.props;
for (n in k) a.call(k, n) && (s = nt(k[n].value), 0 === n.indexOf("@") ? h.setAttribute(n.substr(1), s) : r.setStyle(h, n, s));
continue
}
} else 0 !== l.edge && (Ot(h, [f, g], [m, v]), l.edge = 0);
for (var C = 0; p - 1 > C; C++)
if (d >= c[C].frame && d <= c[C + 1].frame) {
var L = c[C],
S = c[C + 1];
for (n in L.props)
if (a.call(L.props, n)) {
var E = (d - L.frame) / (S.frame - L.frame);
E = L.props[n].easing(E), s = it(L.props[n].value, S.props[n].value, E), s = nt(s), 0 === n.indexOf("@") ? h.setAttribute(n.substr(1), s) : r.setStyle(h, n, s)
}
T && x !== C && ("down" === Rt ? Ct(h, L.eventType, Rt) : Ct(h, S.eventType, Rt), l.lastFrameIndex = C);
break
}
}
},
K = function() {
Bt && (Bt = !1, Lt());
var t, e, i = at.getScrollTop(),
n = Pt();
if (ft) n >= ft.endTime ? (i = ft.targetTop, t = ft.done, ft = o) : (e = ft.easing((n - ft.startTime) / ft.duration), i = ft.startTop + e * ft.topDiff | 0), at.setScrollTop(i, !0);
else if (!yt) {
var s = vt.targetTop - i;
s && (vt = {
startTop: At,
topDiff: i - At,
targetTop: i,
startTime: Ht,
endTime: Ht + gt
}), n <= vt.endTime && (e = V.sqrt((n - vt.startTime) / gt), i = vt.startTop + e * vt.topDiff | 0)
}
if (yt || At !== i) {
Rt = i > At ? "down" : At > i ? "up" : Rt, yt = !1;
var a = {
curTop: i,
lastTop: At,
maxTop: Dt,
direction: Rt
},
l = dt.beforerender && dt.beforerender.call(at, a);
l !== !1 && (Q(i, at.getScrollTop()), Yt && ht && r.setStyle(ht, "transform", "translate(0, " + -Ut + "px) " + bt), At = i, dt.render && dt.render.call(at, a)), t && t.call(at, !1)
}
Ht = n
},
J = function(t) {
for (var e = 0, o = t.keyFrames.length; o > e; e++) {
for (var i, n, s, r, a = t.keyFrames[e], l = {}; null !== (r = D.exec(a.props));) s = r[1], n = r[2], i = s.match(M), null !== i ? (s = i[1], i = i[2]) : i = T, n = n.indexOf("!") ? tt(n) : [n.slice(1)], l[s] = {
value: n,
easing: V[i]
};
a.props = l
}
},
tt = function(t) {
var e = [];
return j.lastIndex = 0, t = t.replace(j, function(t) {
return t.replace(H, function(t) {
return t / 255 * 100 + "%"
})
}), Y && (B.lastIndex = 0, t = t.replace(B, function(t) {
return Y + t
})), t = t.replace(H, function(t) {
return e.push(+t), "{?}"
}), e.unshift(t), e
},
et = function(t) {
var e, o, i = {};
for (e = 0, o = t.keyFrames.length; o > e; e++) ot(t.keyFrames[e], i);
for (i = {}, e = t.keyFrames.length - 1; e >= 0; e--) ot(t.keyFrames[e], i)
},
ot = function(t, e) {
var o;
for (o in e) a.call(t.props, o) || (t.props[o] = e[o]);
for (o in t.props) e[o] = t.props[o]
},
it = function(t, e, o) {
var i, n = t.length;
if (n !== e.length) throw "Can't interpolate between \"" + t[0] + '" and "' + e[0] + '"';
var s = [t[0]];
for (i = 1; n > i; i++) s[i] = t[i] + (e[i] - t[i]) * o;
return s
},
nt = function(t) {
var e = 1;
return N.lastIndex = 0, t[0].replace(N, function() {
return t[e++]
})
},
st = function(t, e) {
t = [].concat(t);
for (var o, i, n = 0, s = t.length; s > n; n++) i = t[n], o = lt[i[_]], o && (e ? (i.style.cssText = o.dirtyStyleAttr, Ot(i, o.dirtyClassAttr)) : (o.dirtyStyleAttr = i.style.cssText, o.dirtyClassAttr = Wt(i), i.style.cssText = o.styleAttr, Ot(i, o.classAttr)))
},
rt = function() {
bt = "translateZ(0)", r.setStyle(ht, "transform", bt);
var t = h(ht),
e = t.getPropertyValue("transform"),
o = t.getPropertyValue(Y + "transform"),
i = e && "none" !== e || o && "none" !== o;
i || (bt = "")
};
r.setStyle = function(t, e, o) {
var i = t.style;
if (e = e.replace(R, A).replace("-", ""), "zIndex" === e) isNaN(o) ? i[e] = o : i[e] = "" + (0 | o);
else if ("float" === e) i.styleFloat = i.cssFloat = o;
else try {
F && (i[F + e.slice(0, 1).toUpperCase() + e.slice(1)] = o), i[e] = o
} catch (t) {}
};
var at, lt, ht, dt, ct, pt, ut, ft, mt, gt, vt, yt, wt, bt, zt, Tt = r.addEvent = function(e, o, i) {
var n = function(e) {
return e = e || t.event, e.target || (e.target = e.srcElement), e.preventDefault || (e.preventDefault = function() {
e.returnValue = !1, e.defaultPrevented = !0
}), i.call(this, e)
};
o = o.split(" ");
for (var s, r = 0, a = o.length; a > r; r++) s = o[r], e.addEventListener ? e.addEventListener(s, i, !1) : e.attachEvent("on" + s, n), qt.push({
element: e,
name: s,
listener: i
})
},
xt = r.removeEvent = function(t, e, o) {
e = e.split(" ");
for (var i = 0, n = e.length; n > i; i++) t.removeEventListener ? t.removeEventListener(e[i], o, !1) : t.detachEvent("on" + e[i], o)
},
kt = function() {
for (var t, e = 0, o = qt.length; o > e; e++) t = qt[e], xt(t.element, t.name, t.listener);
qt = []
},
Ct = function(t, e, o) {
dt.keyframe && dt.keyframe.call(at, t, e, o)
},
Lt = function() {
var t = at.getScrollTop();
Dt = 0, ct && !Yt && (s.style.height = ""), G(), ct && !Yt && (s.style.height = Dt + n.clientHeight + "px"), Yt ? at.setScrollTop(l.min(at.getScrollTop(), Dt)) : at.setScrollTop(t, !0), yt = !0
},
St = function() {
var t, e, o = n.clientHeight,
i = {};
for (t in pt) e = pt[t], "function" == typeof e ? e = e.call(at) : /p$/.test(e) && (e = e.slice(0, -1) / 100 * o), i[t] = e;
return i
},
Et = function() {
var t, e = 0;
return ht && (e = l.max(ht.offsetHeight, ht.scrollHeight)), t = l.max(e, s.scrollHeight, s.offsetHeight, n.scrollHeight, n.offsetHeight, n.clientHeight), t - n.clientHeight
},
Wt = function(e) {
var o = "className";
return t.SVGElement && e instanceof t.SVGElement && (e = e[o], o = "baseVal"), e[o]
},
Ot = function(e, i, n) {
var s = "className";
if (t.SVGElement && e instanceof t.SVGElement && (e = e[s], s = "baseVal"), n === o) return void(e[s] = i);
for (var r = e[s], a = 0, l = n.length; l > a; a++) r = It(r).replace(It(n[a]), " ");
r = _t(r);
for (var h = 0, d = i.length; d > h; h++) - 1 === It(r).indexOf(It(i[h])) && (r += " " + i[h]);
e[s] = _t(r)
},
_t = function(t) {
return t.replace(P, "")
},
It = function(t) {
return " " + t + " "
},
Pt = Date.now || function() {
return +new Date
},
$t = function(t, e) {
return t.frame - e.frame
},
Dt = 0,
Mt = 1,
Rt = "down",
At = -1,
Ht = Pt(),
Nt = 0,
jt = 0,
Bt = !1,
Ft = 0,
Yt = !1,
Ut = 0,
qt = [];
"function" == typeof define && define.amd ? define([], function() {
return r
}) : "undefined" != typeof module && module.exports ? module.exports = r : t.skrollr = r
}(window, document), "function" != typeof Object.create && (Object.create = function(t) {
function e() {}
return e.prototype = t, new e
}),
function(t, e, o) {
var i = function(t) {
var i = o.createElement("script"),
s = o.getElementsByTagName("head")[0];
"file://" == e.location.origin ? i.src = "http://www.youtube.com/iframe_api" : i.src = "//www.youtube.com/iframe_api", s.appendChild(i), s = null, i = null, n(t)
},
n = function(o) {
"undefined" == typeof YT && "undefined" == typeof e.loadingPlayer ? (e.loadingPlayer = !0, e.dfd = t.Deferred(), e.onYouTubeIframeAPIReady = function() {
e.onYouTubeIframeAPIReady = null, e.dfd.resolve("done"), o()
}) : "object" == typeof YT ? o() : e.dfd.done(function(t) {
o()
})
};
YTPlayer = {
player: null,
defaults: {
ratio: 16 / 9,
videoId: "LSmgKRx5pBo",
mute: !0,
repeat: !0,
width: t(e).width(),
playButtonClass: "YTPlayer-play",
pauseButtonClass: "YTPlayer-pause",
muteButtonClass: "YTPlayer-mute",
volumeUpClass: "YTPlayer-volume-up",
volumeDownClass: "YTPlayer-volume-down",
start: 0,
pauseOnScroll: !1,
fitToBackground: !0,
playerVars: {
iv_load_policy: 3,
modestbranding: 1,
autoplay: 1,
controls: 0,
showinfo: 0,
wmode: "opaque",
branding: 0,
autohide: 0
},
events: null
},
init: function(o, n) {
var s = this;
return s.userOptions = n, s.$body = t("body"), s.$node = t(o), s.$window = t(e), s.defaults.events = {
onReady: function(t) {
s.onPlayerReady(t), s.options.pauseOnScroll && s.pauseOnScroll(), "function" == typeof s.options.callback && s.options.callback.call(this)
},
onStateChange: function(t) {
1 === t.data ? (s.$node.find("img").fadeOut(400), s.$node.addClass("loaded")) : 0 === t.data && s.options.repeat && s.player.seekTo(s.options.start)
}
}, s.options = t.extend(!0, {}, s.defaults, s.userOptions), s.options.height = Math.ceil(s.options.width / s.options.ratio), s.ID = (new Date).getTime(), s.holderID = "YTPlayer-ID-" + s.ID, s.options.fitToBackground ? s.createBackgroundVideo() : s.createContainerVideo(), s.$window.on("resize.YTplayer" + s.ID, function() {
s.resize(s)
}), i(s.onYouTubeIframeAPIReady.bind(s)), s.resize(s), s
},
pauseOnScroll: function() {
var t = this;
t.$window.on("scroll.YTplayer" + t.ID, function() {
var e = t.player.getPlayerState();
1 === e && t.player.pauseVideo()
}), t.$window.scrollStopped(function() {
var e = t.player.getPlayerState();
2 === e && t.player.playVideo()
})
},
createContainerVideo: function() {
var e = this,
o = t('
');
e.$node.append(o), e.$YTPlayerString = o, o = null
},
createBackgroundVideo: function() {
var e = this,
o = t('
');
e.$node.append(o), e.$YTPlayerString = o, o = null
},
resize: function(o) {
var i = t(e);
o.options.fitToBackground || (i = o.$node);
var n, s, r = i.width(),
a = i.height(),
l = t("#" + o.holderID);
r / o.options.ratio < a ? (n = Math.ceil(a * o.options.ratio), l.width(n).height(a).css({
left: (r - n) / 2,
top: 0
})) : (s = Math.ceil(r / o.options.ratio), l.width(r).height(s).css({
left: 0,
top: (a - s) / 2
})), l = null, i = null
},
onYouTubeIframeAPIReady: function() {
var t = this;
t.player = new e.YT.Player(t.holderID, t.options)
},
onPlayerReady: function(t) {
this.options.mute && t.target.mute(), t.target.playVideo()
},
getPlayer: function() {
return this.player
},
destroy: function() {
var o = this;
o.$node.removeData("yt-init").removeData("ytPlayer").removeClass("loaded"), o.$YTPlayerString.remove(), t(e).off("resize.YTplayer" + o.ID), t(e).off("scroll.YTplayer" + o.ID), o.$body = null, o.$node = null, o.$YTPlayerString = null, o.player.destroy(), o.player = null
}
}, t.fn.scrollStopped = function(e) {
var o = t(this),
i = this;
o.scroll(function() {
o.data("scrollTimeout") && clearTimeout(o.data("scrollTimeout")), o.data("scrollTimeout", setTimeout(e, 250, i))
})
}, t.fn.YTPlayer = function(e) {
return this.each(function() {
var o = this;
t(o).data("yt-init", !0);
var i = Object.create(YTPlayer);
i.init(o, e), t.data(o, "ytPlayer", i)
})
}
}(jQuery, window, document),
function() {
function t(t, e, i) {
o(e);
var n = t.style,
s = {};
for (var r in e) i && (s[r] = n[r] || ""), n[r] = e[r];
return s
}
function e() {
var t = {},
e = ["webkitTransition", "transition", "mozTransition"],
o = ["webkitTransform", "transform", "mozTransform"],
i = {
transition: "transitionend",
mozTransition: "transitionend",
webkitTransition: "webkitTransitionEnd"
};
return e.some(function(e) {
if (void 0 !== d.style[e]) return t.transition = e, t.transEnd = i[e], !0
}), o.some(function(e) {
if (void 0 !== d.style[e]) return t.transform = e, !0
}), t
}
function o(t) {
var e;
t.transition && (e = t.transition, delete t.transition, t[g] = e), t.transform && (e = t.transform, delete t.transform, t[v] = e)
}
function i(e, o) {
for (var i, n = getComputedStyle(e), s = document.createElement("div"), r = b.length; r--;) i = b[r], s.style[i] = n[i];
return t(s, {
visibility: "hidden",
width: o.width + "px",
height: o.height + "px",
display: "inline" === n.display ? "inline-block" : n.display
}), f.deepCopy ? s.innerHTML = e.innerHTML : s.textContent = e.textContent, s
}
var n, s, r, a, l = "WebkitAppearance" in document.documentElement.style ? "-webkit-" : "",
h = /^([\d\.]+)%$/,
d = document.createElement("div"),
c = document.createElement("div"),
p = !1,
u = !1,
f = {
transitionDuration: ".4s",
transitionTimingFunction: "cubic-bezier(.4,0,0,1)",
bgColor: "#fff",
bgOpacity: 1,
maxWidth: 300,
maxHeight: 300,
onOpen: null,
onClose: null,
onBeforeClose: null,
onBeforeOpen: null
},
m = e(),
g = m.transition,
v = m.transform,
y = v.replace(/(.*)Transform/, "-$1-transform"),
w = m.transEnd;
t(d, {
position: "fixed",
display: "none",
zIndex: 99998,
top: 0,
left: 0,
right: 0,
bottom: 0,
opacity: 0,
backgroundColor: f.bgColor,
cursor: l + "zoom-out",
transition: "opacity " + f.transitionDuration + " " + f.transitionTimingFunction
}), t(c, {
position: "fixed",
zIndex: 99999,
top: "50%",
left: "50%",
width: 0,
height: 0
});
var b = ["position", "display", "float", "top", "left", "right", "bottom", "marginBottom", "marginLeft", "marginRight", "marginTop", "font", "lineHeight", "verticalAlign"],
z = {
config: function(e) {
if (!e) return f;
for (var o in e) f[o] = e[o];
return t(d, {
backgroundColor: f.bgColor,
transition: "opacity " + f.transitionDuration + " " + f.transitionTimingFunction
}), this
},
open: function(e, o) {
if (!p && !u) {
n = "string" == typeof e ? document.querySelector(e) : e, f.onBeforeOpen && f.onBeforeOpen(n), p = !0, u = !0, s = n.parentNode;
var m = n.getBoundingClientRect(),
g = Math.min(f.maxWidth / m.width, f.maxHeight / m.height),
v = m.left - (window.innerWidth - m.width) / 2,
b = m.top - (window.innerHeight - m.height) / 2;
r = i(n, m), a = t(n, {
position: "absolute",
top: 0,
left: 0,
right: "",
bottom: "",
whiteSpace: "nowrap",
marginTop: -m.height / 2 + "px",
marginLeft: -m.width / 2 + "px",
cursor: l + "zoom-out",
transform: "translate(" + v + "px, " + b + "px)",
transition: ""
}, !0);
var z = n.style.width.match(h),
T = n.style.height.match(h);
if (z || T) {
var x = z ? +z[1] / 100 : 1,
k = T ? +T[1] / 100 : 1;
t(c, {
width: ~~(m.width / x) + "px",
height: ~~(m.height / k) + "px"
})
}
s.appendChild(d), s.appendChild(c), s.insertBefore(r, n), c.appendChild(n), d.style.display = "block";
n.offsetHeight;
return d.style.opacity = f.bgOpacity, t(n, {
transition: y + " " + f.transitionDuration + " " + f.transitionTimingFunction,
transform: "scale(" + g + ")"
}), n.addEventListener(w, function t() {
n.removeEventListener(w, t), u = !1, o = o || f.onOpen, o && o(n)
}), this
}
},
close: function(e) {
if (p && !u) {
u = !0, f.onBeforeClose && f.onBeforeClose(n);
var o = r.getBoundingClientRect(),
i = o.left - (window.innerWidth - o.width) / 2,
l = o.top - (window.innerHeight - o.height) / 2;
return d.style.opacity = 0, t(n, {
transform: "translate(" + i + "px, " + l + "px)"
}), n.addEventListener(w, function o() {
n.removeEventListener(w, o), t(n, a), s.insertBefore(n, r), s.removeChild(r), s.removeChild(d), s.removeChild(c), d.style.display = "none", r = null, p = !1, u = !1, e = "function" == typeof e ? e : f.onClose, e && e(n)
}), this
}
},
listen: function e(o) {
if ("string" != typeof o) return t(o, {
cursor: l + "zoom-in"
}), o.addEventListener("click", function(t) {
t.stopPropagation(), p ? z.close() : z.open(o)
}), this;
for (var i = document.querySelectorAll(o), n = i.length; n--;) e(i[n])
}
};
d.addEventListener("click", z.close), c.addEventListener("click", z.close), "object" == typeof exports ? module.exports = z : "function" == typeof define && define.amd ? define(function() {
return z
}) : this.Zoomerang = z
}(), $(function() {
$("#spacial-slider").length && slider.initialize()
});
var slider = {
initialize: function() {
function t() {
h.addEventListener("click", function(t) {
t.preventDefault(), navigate_slider("next"), clearInterval(window.slider_interval)
}), d.addEventListener("click", function(t) {
t.preventDefault(), navigate_slider("prev"), clearInterval(window.slider_interval)
})
}
var e = {
animations: Modernizr.cssanimations
},
o = {
WebkitAnimation: "webkitAnimationEnd",
OAnimation: "oAnimationEnd",
msAnimation: "MSAnimationEnd",
animation: "animationend"
},
i = o[Modernizr.prefixed("animation")],
n = document.getElementById("spacial-slider"),
s = n.querySelector("ul.itemwrap").children,
r = 0,
a = s.length,
l = n.querySelector("nav"),
h = l.querySelector(".next"),
d = l.querySelector(".prev"),
c = !1;
window.navigate_slider = function(t) {
if (c) return !1;
c = !0;
var o = 0,
n = s[r];
"next" === t ? r = r < a - 1 ? r + 1 : 0 : "prev" === t && (r = r > 0 ? r - 1 : a - 1);
var l = s[r],
h = function() {
this.removeEventListener(i, h), $(this).removeClass("current"), $(this).removeClass("next" === t ? "navOutNext" : "navOutPrev"), ++o, 2 === o && (c = !1)
},
d = function() {
this.removeEventListener(i, d), $(this).addClass("current"), $(this).removeClass("next" === t ? "navInNext" : "navInPrev"), ++o, 2 === o && (c = !1)
};
e.animations ? (n.addEventListener(i, h), l.addEventListener(i, d)) : (h(), d()), $(n).addClass("next" === t ? "navOutNext" : "navOutPrev"), $(l).addClass("next" === t ? "navInNext" : "navInPrev")
}, t()
}
};
/** 홈페이지 기본 정의 **/
$(function() {
navbar.initialize(), settings.initialize(), pricing_charts.initialize(), global_notifications.initialize(), ecommerce.initialize(), retina.initialize(), zoomerang.initialize()
});
var settings = {
initialize: function() {
var t = $("#settings-module"),
e = $("#open-settings", t),
o = $("[data-option='navbar']", t),
i = $("nav.navbar"),
n = $("body, html");
e.click(function(e) {
e.preventDefault(), t.toggleClass("opened")
}), o.click(function(t) {
t.preventDefault();
var e = $(this).data("class");
i.removeClass("navbar-default navbar-transparent navbar-inverse").addClass(e), "navbar-default" === e ? i.find(".navbar-brand img").attr("src", "image/logo-alt-b.png") : i.find(".navbar-brand img").attr("src", "image/logo-alt-w.png")
}), n.click(function() {
t.removeClass("opened")
}), t.click(function(t) {
t.stopPropagation()
}), t.length && ((new Image).src = "image/logo-alt-w.png", (new Image).src = "image/logo-alt-b.png")
}
},
zoomerang = {
initialize: function() {
Zoomerang.config({
maxHeight: 730,
maxWidth: 900
}).listen('[data-trigger="zoomerang"]')
}
},
ecommerce = {
initialize: function() {
this.displayCart(), this.search()
},
displayCart: function() {
var t, e = $(".store-navbar .cart"),
o = $("#cart-modal"),
i = function() {
o.addClass("visible"), clearTimeout(t), t = null
},
n = function() {
t = setTimeout(function() {
o.removeClass("visible")
}, 400)
};
e.hover(i, n), o.hover(i, n)
},
search: function() {
var t = $(".store-navbar .search-field"),
e = t.find(".input-search");
e.focus(function() {
t.addClass("focus")
}), e.blur(function() {
t.removeClass("focus")
})
}
},
navbar = {
initialize: function() {
this.themeSites(), window.utils.isMobile() || this.dropdowns()
},
dropdowns: function() {
var t = $(".navbar-nav li.dropdown");
t.each(function(t, e) {
var o = $(this);
o.hover(function() {
o.addClass("open")
}, function() {
o.removeClass("open")
})
})
},
themeSites: function() {
var t = $("[data-toggle-header-sections-menu]"),
e = $("#header-sections-menu"),
o = $("body");
t.click(function(i) {
if (i.preventDefault(), o.toggleClass("header-panel-visible"), o.hasClass("header-panel-visible")) {
t.find("i").removeClass("ion-plus").addClass("ion-minus");
var n = t.closest(".navbar");
if (n.hasClass("navbar-transparent")) return void e.removeClass("fixed");
n.hasClass("navbar-fixed-top") && e.addClass("fixed")
} else t.find("i").removeClass("ion-minus").addClass("ion-plus")
})
}
},
global_notifications = {
initialize: function() {
setTimeout(function() {
$(".global-notification").removeClass("uber-notification").addClass("uber-notification-remove")
}, 5e3)
}
},
pricing_charts = {
initialize: function() {
var t = $(".pricing-charts-tabs .tab"),
e = $(".pricing-charts .chart header .price");
t.click(function() {
t.removeClass("active"), $(this).addClass("active");
var o = $(this).data("tab"),
i = e.filter(":not(." + o + ")");
i.addClass("go-out"), e.filter("." + o).addClass("active"), setTimeout(function() {
i.removeClass("go-out").removeClass("active")
}, 250)
})
}
},
retina = {
initialize: function() {
window.devicePixelRatio >= 1.2 && $("[data-2x]").each(function() {
"IMG" == this.tagName ? $(this).attr("src", $(this).attr("data-2x")) : $(this).css({
"background-image": "url(" + $(this).attr("data-2x") + ")"
})
})
}
};
window.utils = {
/*
load_product_detail: function(classify) {
if(classify=='product_ceil_dryer'){
$(".collection-products").load("product_detail_load.html");
}
},
*/
isFirefox: function() {
return navigator.userAgent.toLowerCase().indexOf("firefox") > -1
},
debounce: function(t, e, o) {
var i;
return function() {
var n = this,
s = arguments,
r = function() {
i = null, o || t.apply(n, s)
},
a = o && !i;
clearTimeout(i), i = setTimeout(r, e), a && t.apply(n, s)
}
},
isMobile: function() {
return window.innerWidth <= 1024
},
parallax_text: function(t, e) {
e = "undefined" != typeof e ? e : 0, $(window).scroll(function() {
var o, i = $(window).scrollTop(),
n = i / 1.4,
s = e + n + "px";
"transform" in document.body.style ? "transform" : "-webkit-transform";
o = i > 0 ? (1e3 - 2.7 * i) / 1e3 : 1, t.css({
position: "relative",
top: s,
opacity: o
})
})
}
};
//# sourceMappingURL=theme.min.js.map