15479 lines
707 KiB
JavaScript
15479 lines
707 KiB
JavaScript
!(function (t) {
|
|
function e(i) {
|
|
if (n[i]) return n[i].exports;
|
|
var o = (n[i] = { i: i, l: false, exports: {} });
|
|
return t[i].call(o.exports, o, o.exports, e), (o.l = true), o.exports;
|
|
}
|
|
var n = {};
|
|
return (
|
|
(e.m = t),
|
|
(e.c = n),
|
|
(e.d = function (t, n, i) {
|
|
if (!e.o(t, n))
|
|
Object.defineProperty(t, n, {
|
|
configurable: false,
|
|
enumerable: true,
|
|
get: i,
|
|
});
|
|
}),
|
|
(e.n = function (t) {
|
|
var n =
|
|
t && t.__esModule
|
|
? function e() {
|
|
return t["default"];
|
|
}
|
|
: function e() {
|
|
return t;
|
|
};
|
|
return e.d(n, "a", n), n;
|
|
}),
|
|
(e.o = function (t, e) {
|
|
return Object.prototype.hasOwnProperty.call(t, e);
|
|
}),
|
|
(e.p = "/Content/BundledScripts/"),
|
|
e((e.s = 9796))
|
|
);
|
|
})({
|
|
10: function (t, e) {
|
|
t.exports = jQuery;
|
|
},
|
|
12: function (t, e, n) {
|
|
"use strict";
|
|
(function (e, i, o, a) {
|
|
function s(t) {
|
|
if (!(8 === t || 16 === t || 24 === t || 32 === t))
|
|
throw new Error("Only 8, 16, 24, or 32 bits supported: " + t);
|
|
}
|
|
function u(t) {
|
|
if (((this.data = ""), (this.read = 0), "string" == typeof t))
|
|
this.data = t;
|
|
else if (util.isArrayBuffer(t) || util.isArrayBufferView(t))
|
|
if (void 0 !== a && t instanceof a) this.data = t.toString("binary");
|
|
else {
|
|
var e = new Uint8Array(t);
|
|
try {
|
|
this.data = String.fromCharCode.apply(null, e);
|
|
} catch (t) {
|
|
for (var n = 0; n < e.length; ++n) this.putByte(e[n]);
|
|
}
|
|
}
|
|
else if (
|
|
t instanceof u ||
|
|
("object" == typeof t &&
|
|
"string" == typeof t.data &&
|
|
"number" == typeof t.read)
|
|
)
|
|
(this.data = t.data), (this.read = t.read);
|
|
this._constructedStringLength = 0;
|
|
}
|
|
function l(t, e) {
|
|
(e = e || {}),
|
|
(this.read = e.readOffset || 0),
|
|
(this.growSize = e.growSize || 1024);
|
|
var n = util.isArrayBuffer(t),
|
|
i = util.isArrayBufferView(t);
|
|
if (n || i) {
|
|
if (n) this.data = new DataView(t);
|
|
else this.data = new DataView(t.buffer, t.byteOffset, t.byteLength);
|
|
return (
|
|
(this.write =
|
|
"writeOffset" in e ? e.writeOffset : this.data.byteLength),
|
|
void 0
|
|
);
|
|
}
|
|
if (
|
|
((this.data = new DataView(new ArrayBuffer(0))),
|
|
(this.write = 0),
|
|
null != t)
|
|
)
|
|
this.putBytes(t);
|
|
if ("writeOffset" in e) this.write = e.writeOffset;
|
|
}
|
|
var f = n(8),
|
|
c = n(382),
|
|
util = (t.exports = f.util = f.util || {});
|
|
!(function () {
|
|
if (void 0 === e || !e.nextTick || e.browser) {
|
|
if ("function" == typeof i)
|
|
return (
|
|
(util.setImmediate = function () {
|
|
return i.apply(void 0, arguments);
|
|
}),
|
|
(util.nextTick = function (t) {
|
|
return i(t);
|
|
}),
|
|
void 0
|
|
);
|
|
if (
|
|
((util.setImmediate = function (t) {
|
|
setTimeout(t, 0);
|
|
}),
|
|
"undefined" != typeof window &&
|
|
"function" == typeof window.postMessage)
|
|
) {
|
|
var t = "forge.setImmediate",
|
|
n = [];
|
|
function e(e) {
|
|
if (e.source === window && e.data === t) {
|
|
e.stopPropagation();
|
|
var copy = n.slice();
|
|
(n.length = 0),
|
|
copy.forEach(function (t) {
|
|
t();
|
|
});
|
|
}
|
|
}
|
|
(util.setImmediate = function (e) {
|
|
if ((n.push(e), 1 === n.length)) window.postMessage(t, "*");
|
|
}),
|
|
window.addEventListener("message", e, true);
|
|
}
|
|
if ("undefined" != typeof MutationObserver) {
|
|
var o = Date.now(),
|
|
a = true,
|
|
s = document.createElement("div"),
|
|
n = [];
|
|
new MutationObserver(function () {
|
|
var copy = n.slice();
|
|
(n.length = 0),
|
|
copy.forEach(function (t) {
|
|
t();
|
|
});
|
|
}).observe(s, { attributes: true });
|
|
var u = util.setImmediate;
|
|
util.setImmediate = function (t) {
|
|
if (Date.now() - o > 15) (o = Date.now()), u(t);
|
|
else if ((n.push(t), 1 === n.length))
|
|
s.setAttribute("a", (a = !a));
|
|
};
|
|
}
|
|
util.nextTick = util.setImmediate;
|
|
} else if (((util.nextTick = e.nextTick), "function" == typeof i))
|
|
util.setImmediate = i;
|
|
else util.setImmediate = util.nextTick;
|
|
})(),
|
|
(util.isNodejs = void 0 !== e && e.versions && e.versions.node),
|
|
(util.globalScope = (function () {
|
|
if (util.isNodejs) return o;
|
|
else return "undefined" == typeof self ? window : self;
|
|
})()),
|
|
(util.isArray =
|
|
Array.isArray ||
|
|
function (t) {
|
|
return "[object Array]" === Object.prototype.toString.call(t);
|
|
}),
|
|
(util.isArrayBuffer = function (t) {
|
|
return "undefined" != typeof ArrayBuffer && t instanceof ArrayBuffer;
|
|
}),
|
|
(util.isArrayBufferView = function (t) {
|
|
return t && util.isArrayBuffer(t.buffer) && void 0 !== t.byteLength;
|
|
}),
|
|
(util.ByteBuffer = u),
|
|
(util.ByteStringBuffer = u);
|
|
var h = 4096;
|
|
(util.ByteStringBuffer.prototype._optimizeConstructedString = function (
|
|
t
|
|
) {
|
|
if (
|
|
((this._constructedStringLength += t),
|
|
this._constructedStringLength > h)
|
|
)
|
|
this.data.substr(0, 1), (this._constructedStringLength = 0);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.length = function () {
|
|
return this.data.length - this.read;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.isEmpty = function () {
|
|
return this.length() <= 0;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putByte = function (t) {
|
|
return this.putBytes(String.fromCharCode(t));
|
|
}),
|
|
(util.ByteStringBuffer.prototype.fillWithByte = function (t, e) {
|
|
t = String.fromCharCode(t);
|
|
for (var d = this.data; e > 0;) {
|
|
if (1 & e) d += t;
|
|
if ((e >>>= 1) > 0) t += t;
|
|
}
|
|
return (this.data = d), this._optimizeConstructedString(e), this;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putBytes = function (t) {
|
|
return (
|
|
(this.data += t), this._optimizeConstructedString(t.length), this
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putString = function (t) {
|
|
return this.putBytes(util.encodeUtf8(t));
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt16 = function (t) {
|
|
return this.putBytes(
|
|
String.fromCharCode((t >> 8) & 255) + String.fromCharCode(255 & t)
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt24 = function (t) {
|
|
return this.putBytes(
|
|
String.fromCharCode((t >> 16) & 255) +
|
|
String.fromCharCode((t >> 8) & 255) +
|
|
String.fromCharCode(255 & t)
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt32 = function (t) {
|
|
return this.putBytes(
|
|
String.fromCharCode((t >> 24) & 255) +
|
|
String.fromCharCode((t >> 16) & 255) +
|
|
String.fromCharCode((t >> 8) & 255) +
|
|
String.fromCharCode(255 & t)
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt16Le = function (t) {
|
|
return this.putBytes(
|
|
String.fromCharCode(255 & t) + String.fromCharCode((t >> 8) & 255)
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt24Le = function (t) {
|
|
return this.putBytes(
|
|
String.fromCharCode(255 & t) +
|
|
String.fromCharCode((t >> 8) & 255) +
|
|
String.fromCharCode((t >> 16) & 255)
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt32Le = function (t) {
|
|
return this.putBytes(
|
|
String.fromCharCode(255 & t) +
|
|
String.fromCharCode((t >> 8) & 255) +
|
|
String.fromCharCode((t >> 16) & 255) +
|
|
String.fromCharCode((t >> 24) & 255)
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putInt = function (t, e) {
|
|
s(e);
|
|
var n = "";
|
|
do {
|
|
(e -= 8), (n += String.fromCharCode((t >> e) & 255));
|
|
} while (e > 0);
|
|
return this.putBytes(n);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putSignedInt = function (t, e) {
|
|
if (t < 0) t += 2 << (e - 1);
|
|
return this.putInt(t, e);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.putBuffer = function (t) {
|
|
return this.putBytes(t.getBytes());
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getByte = function () {
|
|
return this.data.charCodeAt(this.read++);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt16 = function () {
|
|
var t =
|
|
(this.data.charCodeAt(this.read) << 8) ^
|
|
this.data.charCodeAt(this.read + 1);
|
|
return (this.read += 2), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt24 = function () {
|
|
var t =
|
|
(this.data.charCodeAt(this.read) << 16) ^
|
|
(this.data.charCodeAt(this.read + 1) << 8) ^
|
|
this.data.charCodeAt(this.read + 2);
|
|
return (this.read += 3), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt32 = function () {
|
|
var t =
|
|
(this.data.charCodeAt(this.read) << 24) ^
|
|
(this.data.charCodeAt(this.read + 1) << 16) ^
|
|
(this.data.charCodeAt(this.read + 2) << 8) ^
|
|
this.data.charCodeAt(this.read + 3);
|
|
return (this.read += 4), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt16Le = function () {
|
|
var t =
|
|
this.data.charCodeAt(this.read) ^
|
|
(this.data.charCodeAt(this.read + 1) << 8);
|
|
return (this.read += 2), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt24Le = function () {
|
|
var t =
|
|
this.data.charCodeAt(this.read) ^
|
|
(this.data.charCodeAt(this.read + 1) << 8) ^
|
|
(this.data.charCodeAt(this.read + 2) << 16);
|
|
return (this.read += 3), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt32Le = function () {
|
|
var t =
|
|
this.data.charCodeAt(this.read) ^
|
|
(this.data.charCodeAt(this.read + 1) << 8) ^
|
|
(this.data.charCodeAt(this.read + 2) << 16) ^
|
|
(this.data.charCodeAt(this.read + 3) << 24);
|
|
return (this.read += 4), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getInt = function (t) {
|
|
s(t);
|
|
var e = 0;
|
|
do {
|
|
(e = (e << 8) + this.data.charCodeAt(this.read++)), (t -= 8);
|
|
} while (t > 0);
|
|
return e;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getSignedInt = function (t) {
|
|
var e = this.getInt(t),
|
|
n = 2 << (t - 2);
|
|
if (e >= n) e -= n << 1;
|
|
return e;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.getBytes = function (t) {
|
|
var e;
|
|
if (t)
|
|
(t = Math.min(this.length(), t)),
|
|
(e = this.data.slice(this.read, this.read + t)),
|
|
(this.read += t);
|
|
else if (0 === t) e = "";
|
|
else
|
|
(e = 0 === this.read ? this.data : this.data.slice(this.read)),
|
|
this.clear();
|
|
return e;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.bytes = function (t) {
|
|
return void 0 === t
|
|
? this.data.slice(this.read)
|
|
: this.data.slice(this.read, this.read + t);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.at = function (t) {
|
|
return this.data.charCodeAt(this.read + t);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.setAt = function (t, e) {
|
|
return (
|
|
(this.data =
|
|
this.data.substr(0, this.read + t) +
|
|
String.fromCharCode(e) +
|
|
this.data.substr(this.read + t + 1)),
|
|
this
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.last = function () {
|
|
return this.data.charCodeAt(this.data.length - 1);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.copy = function () {
|
|
var t = util.createBuffer(this.data);
|
|
return (t.read = this.read), t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.compact = function () {
|
|
if (this.read > 0)
|
|
(this.data = this.data.slice(this.read)), (this.read = 0);
|
|
return this;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.clear = function () {
|
|
return (this.data = ""), (this.read = 0), this;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.truncate = function (t) {
|
|
var e = Math.max(0, this.length() - t);
|
|
return (
|
|
(this.data = this.data.substr(this.read, e)), (this.read = 0), this
|
|
);
|
|
}),
|
|
(util.ByteStringBuffer.prototype.toHex = function () {
|
|
for (var t = "", e = this.read; e < this.data.length; ++e) {
|
|
var n = this.data.charCodeAt(e);
|
|
if (n < 16) t += "0";
|
|
t += n.toString(16);
|
|
}
|
|
return t;
|
|
}),
|
|
(util.ByteStringBuffer.prototype.toString = function () {
|
|
return util.decodeUtf8(this.bytes());
|
|
}),
|
|
(util.DataBuffer = l),
|
|
(util.DataBuffer.prototype.length = function () {
|
|
return this.write - this.read;
|
|
}),
|
|
(util.DataBuffer.prototype.isEmpty = function () {
|
|
return this.length() <= 0;
|
|
}),
|
|
(util.DataBuffer.prototype.accommodate = function (t, e) {
|
|
if (this.length() >= t) return this;
|
|
e = Math.max(e || this.growSize, t);
|
|
var n = new Uint8Array(
|
|
this.data.buffer,
|
|
this.data.byteOffset,
|
|
this.data.byteLength
|
|
),
|
|
i = new Uint8Array(this.length() + e);
|
|
return i.set(n), (this.data = new DataView(i.buffer)), this;
|
|
}),
|
|
(util.DataBuffer.prototype.putByte = function (t) {
|
|
return this.accommodate(1), this.data.setUint8(this.write++, t), this;
|
|
}),
|
|
(util.DataBuffer.prototype.fillWithByte = function (t, e) {
|
|
this.accommodate(e);
|
|
for (var n = 0; n < e; ++n) this.data.setUint8(t);
|
|
return this;
|
|
}),
|
|
(util.DataBuffer.prototype.putBytes = function (t, e) {
|
|
if (util.isArrayBufferView(t)) {
|
|
var n,
|
|
i =
|
|
(n = new Uint8Array(t.buffer, t.byteOffset, t.byteLength))
|
|
.byteLength - n.byteOffset,
|
|
o;
|
|
return (
|
|
this.accommodate(i),
|
|
(o = new Uint8Array(this.data.buffer, this.write)).set(n),
|
|
(this.write += i),
|
|
this
|
|
);
|
|
}
|
|
if (util.isArrayBuffer(t)) {
|
|
var n = new Uint8Array(t),
|
|
o;
|
|
return (
|
|
this.accommodate(n.byteLength),
|
|
(o = new Uint8Array(this.data.buffer)).set(n, this.write),
|
|
(this.write += n.byteLength),
|
|
this
|
|
);
|
|
}
|
|
if (
|
|
t instanceof util.DataBuffer ||
|
|
("object" == typeof t &&
|
|
"number" == typeof t.read &&
|
|
"number" == typeof t.write &&
|
|
util.isArrayBufferView(t.data))
|
|
) {
|
|
var n = new Uint8Array(t.data.byteLength, t.read, t.length()),
|
|
o;
|
|
return (
|
|
this.accommodate(n.byteLength),
|
|
(o = new Uint8Array(t.data.byteLength, this.write)).set(n),
|
|
(this.write += n.byteLength),
|
|
this
|
|
);
|
|
}
|
|
if (t instanceof util.ByteStringBuffer) (t = t.data), (e = "binary");
|
|
if (((e = e || "binary"), "string" == typeof t)) {
|
|
var view;
|
|
if ("hex" === e)
|
|
return (
|
|
this.accommodate(Math.ceil(t.length / 2)),
|
|
(view = new Uint8Array(this.data.buffer, this.write)),
|
|
(this.write += util.binary.hex.decode(t, view, this.write)),
|
|
this
|
|
);
|
|
if ("base64" === e)
|
|
return (
|
|
this.accommodate(3 * Math.ceil(t.length / 4)),
|
|
(view = new Uint8Array(this.data.buffer, this.write)),
|
|
(this.write += util.binary.base64.decode(t, view, this.write)),
|
|
this
|
|
);
|
|
if ("utf8" === e) (t = util.encodeUtf8(t)), (e = "binary");
|
|
if ("binary" === e || "raw" === e)
|
|
return (
|
|
this.accommodate(t.length),
|
|
(view = new Uint8Array(this.data.buffer, this.write)),
|
|
(this.write += util.binary.raw.decode(view)),
|
|
this
|
|
);
|
|
if ("utf16" === e)
|
|
return (
|
|
this.accommodate(2 * t.length),
|
|
(view = new Uint16Array(this.data.buffer, this.write)),
|
|
(this.write += util.text.utf16.encode(view)),
|
|
this
|
|
);
|
|
throw new Error("Invalid encoding: " + e);
|
|
}
|
|
throw Error("Invalid parameter: " + t);
|
|
}),
|
|
(util.DataBuffer.prototype.putBuffer = function (t) {
|
|
return this.putBytes(t), t.clear(), this;
|
|
}),
|
|
(util.DataBuffer.prototype.putString = function (t) {
|
|
return this.putBytes(t, "utf16");
|
|
}),
|
|
(util.DataBuffer.prototype.putInt16 = function (t) {
|
|
return (
|
|
this.accommodate(2),
|
|
this.data.setInt16(this.write, t),
|
|
(this.write += 2),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.putInt24 = function (t) {
|
|
return (
|
|
this.accommodate(3),
|
|
this.data.setInt16(this.write, (t >> 8) & 65535),
|
|
this.data.setInt8(this.write, (t >> 16) & 255),
|
|
(this.write += 3),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.putInt32 = function (t) {
|
|
return (
|
|
this.accommodate(4),
|
|
this.data.setInt32(this.write, t),
|
|
(this.write += 4),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.putInt16Le = function (t) {
|
|
return (
|
|
this.accommodate(2),
|
|
this.data.setInt16(this.write, t, true),
|
|
(this.write += 2),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.putInt24Le = function (t) {
|
|
return (
|
|
this.accommodate(3),
|
|
this.data.setInt8(this.write, (t >> 16) & 255),
|
|
this.data.setInt16(this.write, (t >> 8) & 65535, true),
|
|
(this.write += 3),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.putInt32Le = function (t) {
|
|
return (
|
|
this.accommodate(4),
|
|
this.data.setInt32(this.write, t, true),
|
|
(this.write += 4),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.putInt = function (t, e) {
|
|
s(e), this.accommodate(e / 8);
|
|
do {
|
|
(e -= 8), this.data.setInt8(this.write++, (t >> e) & 255);
|
|
} while (e > 0);
|
|
return this;
|
|
}),
|
|
(util.DataBuffer.prototype.putSignedInt = function (t, e) {
|
|
if ((s(e), this.accommodate(e / 8), t < 0)) t += 2 << (e - 1);
|
|
return this.putInt(t, e);
|
|
}),
|
|
(util.DataBuffer.prototype.getByte = function () {
|
|
return this.data.getInt8(this.read++);
|
|
}),
|
|
(util.DataBuffer.prototype.getInt16 = function () {
|
|
var t = this.data.getInt16(this.read);
|
|
return (this.read += 2), t;
|
|
}),
|
|
(util.DataBuffer.prototype.getInt24 = function () {
|
|
var t =
|
|
(this.data.getInt16(this.read) << 8) ^
|
|
this.data.getInt8(this.read + 2);
|
|
return (this.read += 3), t;
|
|
}),
|
|
(util.DataBuffer.prototype.getInt32 = function () {
|
|
var t = this.data.getInt32(this.read);
|
|
return (this.read += 4), t;
|
|
}),
|
|
(util.DataBuffer.prototype.getInt16Le = function () {
|
|
var t = this.data.getInt16(this.read, true);
|
|
return (this.read += 2), t;
|
|
}),
|
|
(util.DataBuffer.prototype.getInt24Le = function () {
|
|
var t =
|
|
this.data.getInt8(this.read) ^
|
|
(this.data.getInt16(this.read + 1, true) << 8);
|
|
return (this.read += 3), t;
|
|
}),
|
|
(util.DataBuffer.prototype.getInt32Le = function () {
|
|
var t = this.data.getInt32(this.read, true);
|
|
return (this.read += 4), t;
|
|
}),
|
|
(util.DataBuffer.prototype.getInt = function (t) {
|
|
s(t);
|
|
var e = 0;
|
|
do {
|
|
(e = (e << 8) + this.data.getInt8(this.read++)), (t -= 8);
|
|
} while (t > 0);
|
|
return e;
|
|
}),
|
|
(util.DataBuffer.prototype.getSignedInt = function (t) {
|
|
var e = this.getInt(t),
|
|
n = 2 << (t - 2);
|
|
if (e >= n) e -= n << 1;
|
|
return e;
|
|
}),
|
|
(util.DataBuffer.prototype.getBytes = function (t) {
|
|
var e;
|
|
if (t)
|
|
(t = Math.min(this.length(), t)),
|
|
(e = this.data.slice(this.read, this.read + t)),
|
|
(this.read += t);
|
|
else if (0 === t) e = "";
|
|
else
|
|
(e = 0 === this.read ? this.data : this.data.slice(this.read)),
|
|
this.clear();
|
|
return e;
|
|
}),
|
|
(util.DataBuffer.prototype.bytes = function (t) {
|
|
return void 0 === t
|
|
? this.data.slice(this.read)
|
|
: this.data.slice(this.read, this.read + t);
|
|
}),
|
|
(util.DataBuffer.prototype.at = function (t) {
|
|
return this.data.getUint8(this.read + t);
|
|
}),
|
|
(util.DataBuffer.prototype.setAt = function (t, e) {
|
|
return this.data.setUint8(t, e), this;
|
|
}),
|
|
(util.DataBuffer.prototype.last = function () {
|
|
return this.data.getUint8(this.write - 1);
|
|
}),
|
|
(util.DataBuffer.prototype.copy = function () {
|
|
return new util.DataBuffer(this);
|
|
}),
|
|
(util.DataBuffer.prototype.compact = function () {
|
|
if (this.read > 0) {
|
|
var t = new Uint8Array(this.data.buffer, this.read),
|
|
e = new Uint8Array(t.byteLength);
|
|
e.set(t),
|
|
(this.data = new DataView(e)),
|
|
(this.write -= this.read),
|
|
(this.read = 0);
|
|
}
|
|
return this;
|
|
}),
|
|
(util.DataBuffer.prototype.clear = function () {
|
|
return (
|
|
(this.data = new DataView(new ArrayBuffer(0))),
|
|
(this.read = this.write = 0),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.truncate = function (t) {
|
|
return (
|
|
(this.write = Math.max(0, this.length() - t)),
|
|
(this.read = Math.min(this.read, this.write)),
|
|
this
|
|
);
|
|
}),
|
|
(util.DataBuffer.prototype.toHex = function () {
|
|
for (var t = "", e = this.read; e < this.data.byteLength; ++e) {
|
|
var n = this.data.getUint8(e);
|
|
if (n < 16) t += "0";
|
|
t += n.toString(16);
|
|
}
|
|
return t;
|
|
}),
|
|
(util.DataBuffer.prototype.toString = function (t) {
|
|
var view = new Uint8Array(this.data, this.read, this.length());
|
|
if ("binary" === (t = t || "utf8") || "raw" === t)
|
|
return util.binary.raw.encode(view);
|
|
if ("hex" === t) return util.binary.hex.encode(view);
|
|
if ("base64" === t) return util.binary.base64.encode(view);
|
|
if ("utf8" === t) return util.text.utf8.decode(view);
|
|
if ("utf16" === t) return util.text.utf16.decode(view);
|
|
throw new Error("Invalid encoding: " + t);
|
|
}),
|
|
(util.createBuffer = function (input, t) {
|
|
if (((t = t || "raw"), void 0 !== input && "utf8" === t))
|
|
input = util.encodeUtf8(input);
|
|
return new util.ByteBuffer(input);
|
|
}),
|
|
(util.fillString = function (t, e) {
|
|
for (var n = ""; e > 0;) {
|
|
if (1 & e) n += t;
|
|
if ((e >>>= 1) > 0) t += t;
|
|
}
|
|
return n;
|
|
}),
|
|
(util.xorBytes = function (t, e, n) {
|
|
for (var i = "", o = "", a = "", s = 0, u = 0; n > 0; --n, ++s) {
|
|
if (((o = t.charCodeAt(s) ^ e.charCodeAt(s)), u >= 10))
|
|
(i += a), (a = ""), (u = 0);
|
|
(a += String.fromCharCode(o)), ++u;
|
|
}
|
|
return (i += a);
|
|
}),
|
|
(util.hexToBytes = function (t) {
|
|
var e = "",
|
|
n = 0;
|
|
if (t.length & (1 == 1))
|
|
(n = 1), (e += String.fromCharCode(parseInt(t[0], 16)));
|
|
for (; n < t.length; n += 2)
|
|
e += String.fromCharCode(parseInt(t.substr(n, 2), 16));
|
|
return e;
|
|
}),
|
|
(util.bytesToHex = function (t) {
|
|
return util.createBuffer(t).toHex();
|
|
}),
|
|
(util.int32ToBytes = function (t) {
|
|
return (
|
|
String.fromCharCode((t >> 24) & 255) +
|
|
String.fromCharCode((t >> 16) & 255) +
|
|
String.fromCharCode((t >> 8) & 255) +
|
|
String.fromCharCode(255 & t)
|
|
);
|
|
});
|
|
var p =
|
|
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",
|
|
m = [
|
|
62, -1, -1, -1, 63, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, -1, -1,
|
|
-1, 64, -1, -1, -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
|
|
15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, -1, -1, -1,
|
|
26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42,
|
|
43, 44, 45, 46, 47, 48, 49, 50, 51,
|
|
],
|
|
v = "123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz";
|
|
(util.encode64 = function (input, t) {
|
|
for (var line = "", e = "", n, i, o, a = 0; a < input.length;) {
|
|
if (
|
|
((n = input.charCodeAt(a++)),
|
|
(i = input.charCodeAt(a++)),
|
|
(o = input.charCodeAt(a++)),
|
|
(line += p.charAt(n >> 2)),
|
|
(line += p.charAt(((3 & n) << 4) | (i >> 4))),
|
|
isNaN(i))
|
|
)
|
|
line += "==";
|
|
else
|
|
(line += p.charAt(((15 & i) << 2) | (o >> 6))),
|
|
(line += isNaN(o) ? "=" : p.charAt(63 & o));
|
|
if (t && line.length > t)
|
|
(e += line.substr(0, t) + "\r\n"), (line = line.substr(t));
|
|
}
|
|
return (e += line);
|
|
}),
|
|
(util.decode64 = function (input) {
|
|
input = input.replace(/[^A-Za-z0-9\+\/\=]/g, "");
|
|
for (var t = "", e, n, i, o, a = 0; a < input.length;)
|
|
if (
|
|
((e = m[input.charCodeAt(a++) - 43]),
|
|
(n = m[input.charCodeAt(a++) - 43]),
|
|
(i = m[input.charCodeAt(a++) - 43]),
|
|
(o = m[input.charCodeAt(a++) - 43]),
|
|
(t += String.fromCharCode((e << 2) | (n >> 4))),
|
|
64 !== i)
|
|
)
|
|
if (
|
|
((t += String.fromCharCode(((15 & n) << 4) | (i >> 2))),
|
|
64 !== o)
|
|
)
|
|
t += String.fromCharCode(((3 & i) << 6) | o);
|
|
return t;
|
|
}),
|
|
(util.encodeUtf8 = function (t) {
|
|
return unescape(encodeURIComponent(t));
|
|
}),
|
|
(util.decodeUtf8 = function (t) {
|
|
return decodeURIComponent(escape(t));
|
|
}),
|
|
(util.binary = {
|
|
raw: {},
|
|
hex: {},
|
|
base64: {},
|
|
base58: {},
|
|
baseN: { encode: c.encode, decode: c.decode },
|
|
}),
|
|
(util.binary.raw.encode = function (t) {
|
|
return String.fromCharCode.apply(null, t);
|
|
}),
|
|
(util.binary.raw.decode = function (t, e, n) {
|
|
var i = e;
|
|
if (!i) i = new Uint8Array(t.length);
|
|
for (var o = (n = n || 0), a = 0; a < t.length; ++a)
|
|
i[o++] = t.charCodeAt(a);
|
|
return e ? o - n : i;
|
|
}),
|
|
(util.binary.hex.encode = util.bytesToHex),
|
|
(util.binary.hex.decode = function (t, e, n) {
|
|
var i = e;
|
|
if (!i) i = new Uint8Array(Math.ceil(t.length / 2));
|
|
var o = 0,
|
|
a = (n = n || 0);
|
|
if (1 & t.length) (o = 1), (i[a++] = parseInt(t[0], 16));
|
|
for (; o < t.length; o += 2) i[a++] = parseInt(t.substr(o, 2), 16);
|
|
return e ? a - n : i;
|
|
}),
|
|
(util.binary.base64.encode = function (input, t) {
|
|
for (var line = "", e = "", n, i, o, a = 0; a < input.byteLength;) {
|
|
if (
|
|
((n = input[a++]),
|
|
(i = input[a++]),
|
|
(o = input[a++]),
|
|
(line += p.charAt(n >> 2)),
|
|
(line += p.charAt(((3 & n) << 4) | (i >> 4))),
|
|
isNaN(i))
|
|
)
|
|
line += "==";
|
|
else
|
|
(line += p.charAt(((15 & i) << 2) | (o >> 6))),
|
|
(line += isNaN(o) ? "=" : p.charAt(63 & o));
|
|
if (t && line.length > t)
|
|
(e += line.substr(0, t) + "\r\n"), (line = line.substr(t));
|
|
}
|
|
return (e += line);
|
|
}),
|
|
(util.binary.base64.decode = function (input, t, e) {
|
|
var n = t,
|
|
i,
|
|
o,
|
|
a,
|
|
s;
|
|
if (!n) n = new Uint8Array(3 * Math.ceil(input.length / 4));
|
|
input = input.replace(/[^A-Za-z0-9\+\/\=]/g, "");
|
|
for (var u = 0, l = (e = e || 0); u < input.length;)
|
|
if (
|
|
((i = m[input.charCodeAt(u++) - 43]),
|
|
(o = m[input.charCodeAt(u++) - 43]),
|
|
(a = m[input.charCodeAt(u++) - 43]),
|
|
(s = m[input.charCodeAt(u++) - 43]),
|
|
(n[l++] = (i << 2) | (o >> 4)),
|
|
64 !== a)
|
|
)
|
|
if (((n[l++] = ((15 & o) << 4) | (a >> 2)), 64 !== s))
|
|
n[l++] = ((3 & a) << 6) | s;
|
|
return t ? l - e : n.subarray(0, l);
|
|
}),
|
|
(util.binary.base58.encode = function (input, t) {
|
|
return util.binary.baseN.encode(input, v, t);
|
|
}),
|
|
(util.binary.base58.decode = function (input, t) {
|
|
return util.binary.baseN.decode(input, v, t);
|
|
}),
|
|
(util.text = { utf8: {}, utf16: {} }),
|
|
(util.text.utf8.encode = function (t, e, n) {
|
|
t = util.encodeUtf8(t);
|
|
var i = e;
|
|
if (!i) i = new Uint8Array(t.length);
|
|
for (var o = (n = n || 0), a = 0; a < t.length; ++a)
|
|
i[o++] = t.charCodeAt(a);
|
|
return e ? o - n : i;
|
|
}),
|
|
(util.text.utf8.decode = function (t) {
|
|
return util.decodeUtf8(String.fromCharCode.apply(null, t));
|
|
}),
|
|
(util.text.utf16.encode = function (t, e, n) {
|
|
var i = e;
|
|
if (!i) i = new Uint8Array(2 * t.length);
|
|
for (
|
|
var view = new Uint16Array(i.buffer),
|
|
o = (n = n || 0),
|
|
a = n,
|
|
s = 0;
|
|
s < t.length;
|
|
++s
|
|
)
|
|
(view[a++] = t.charCodeAt(s)), (o += 2);
|
|
return e ? o - n : i;
|
|
}),
|
|
(util.text.utf16.decode = function (t) {
|
|
return String.fromCharCode.apply(null, new Uint16Array(t.buffer));
|
|
}),
|
|
(util.deflate = function (t, e, n) {
|
|
if (((e = util.decode64(t.deflate(util.encode64(e)).rval)), n)) {
|
|
var i = 2,
|
|
o;
|
|
if (32 & e.charCodeAt(1)) i = 6;
|
|
e = e.substring(i, e.length - 4);
|
|
}
|
|
return e;
|
|
}),
|
|
(util.inflate = function (t, e, n) {
|
|
var i = t.inflate(util.encode64(e)).rval;
|
|
return null === i ? null : util.decode64(i);
|
|
});
|
|
var g = function (t, id, e) {
|
|
if (!t) throw new Error("WebStorage not available.");
|
|
var n;
|
|
if (null === e) n = t.removeItem(id);
|
|
else (e = util.encode64(JSON.stringify(e))), (n = t.setItem(id, e));
|
|
if (void 0 !== n && true !== n.rval) {
|
|
var i = new Error(n.error.message);
|
|
throw ((i.id = n.error.id), (i.name = n.error.name), i);
|
|
}
|
|
},
|
|
y = function (t, id) {
|
|
if (!t) throw new Error("WebStorage not available.");
|
|
var e = t.getItem(id);
|
|
if (t.init)
|
|
if (null === e.rval) {
|
|
if (e.error) {
|
|
var n = new Error(e.error.message);
|
|
throw ((n.id = e.error.id), (n.name = e.error.name), n);
|
|
}
|
|
e = null;
|
|
} else e = e.rval;
|
|
if (null !== e) e = JSON.parse(util.decode64(e));
|
|
return e;
|
|
},
|
|
w = function (t, id, e, data) {
|
|
var n = y(t, id);
|
|
if (null === n) n = {};
|
|
(n[e] = data), g(t, id, n);
|
|
},
|
|
b = function (t, id, e) {
|
|
var n = y(t, id);
|
|
if (null !== n) n = e in n ? n[e] : null;
|
|
return n;
|
|
},
|
|
C = function (t, id, e) {
|
|
var n = y(t, id);
|
|
if (null !== n && e in n) {
|
|
delete n[e];
|
|
var empty = true;
|
|
for (var i in n) {
|
|
empty = false;
|
|
break;
|
|
}
|
|
if (empty) n = null;
|
|
g(t, id, n);
|
|
}
|
|
},
|
|
x = function (t, id) {
|
|
g(t, id, null);
|
|
},
|
|
S = function (t, e, n) {
|
|
var i = null,
|
|
type;
|
|
if (void 0 === n) n = ["web", "flash"];
|
|
var o = false,
|
|
a = null;
|
|
for (var s in n) {
|
|
type = n[s];
|
|
try {
|
|
if ("flash" === type || "both" === type) {
|
|
if (null === e[0])
|
|
throw new Error("Flash local storage not available.");
|
|
(i = t.apply(this, e)), (o = "flash" === type);
|
|
}
|
|
if ("web" === type || "both" === type)
|
|
(e[0] = localStorage), (i = t.apply(this, e)), (o = true);
|
|
} catch (t) {
|
|
a = t;
|
|
}
|
|
if (o) break;
|
|
}
|
|
if (!o) throw a;
|
|
return i;
|
|
};
|
|
(util.setItem = function (t, id, e, data, n) {
|
|
S(w, arguments, n);
|
|
}),
|
|
(util.getItem = function (t, id, e, n) {
|
|
return S(b, arguments, n);
|
|
}),
|
|
(util.removeItem = function (t, id, e, n) {
|
|
S(C, arguments, n);
|
|
}),
|
|
(util.clearItems = function (t, id, e) {
|
|
S(x, arguments, e);
|
|
}),
|
|
(util.isEmpty = function (t) {
|
|
for (var e in t) if (t.hasOwnProperty(e)) return false;
|
|
return true;
|
|
}),
|
|
(util.format = function (format) {
|
|
for (
|
|
var t = /%./g, e, n, i = 0, o = [], a = 0;
|
|
(e = t.exec(format));
|
|
|
|
) {
|
|
if ((n = format.substring(a, t.lastIndex - 2)).length > 0)
|
|
o.push(n);
|
|
a = t.lastIndex;
|
|
var s = e[0][1];
|
|
switch (s) {
|
|
case "s":
|
|
case "o":
|
|
if (i < arguments.length) o.push(arguments[i++ + 1]);
|
|
else o.push("<?>");
|
|
break;
|
|
case "%":
|
|
o.push("%");
|
|
break;
|
|
default:
|
|
o.push("<%" + s + "?>");
|
|
}
|
|
}
|
|
return o.push(format.substring(a)), o.join("");
|
|
}),
|
|
(util.formatNumber = function (t, e, n, i) {
|
|
var o = t,
|
|
a = isNaN((e = Math.abs(e))) ? 2 : e,
|
|
d = void 0 === n ? "," : n,
|
|
s = void 0 === i ? "." : i,
|
|
u = o < 0 ? "-" : "",
|
|
l = parseInt((o = Math.abs(+o || 0).toFixed(a)), 10) + "",
|
|
f = l.length > 3 ? l.length % 3 : 0;
|
|
return (
|
|
u +
|
|
(f ? l.substr(0, f) + s : "") +
|
|
l.substr(f).replace(/(\d{3})(?=\d)/g, "$1" + s) +
|
|
(a
|
|
? d +
|
|
Math.abs(o - l)
|
|
.toFixed(a)
|
|
.slice(2)
|
|
: "")
|
|
);
|
|
}),
|
|
(util.formatSize = function (size) {
|
|
if (size >= 1073741824)
|
|
size = util.formatNumber(size / 1073741824, 2, ".", "") + " GiB";
|
|
else if (size >= 1048576)
|
|
size = util.formatNumber(size / 1048576, 2, ".", "") + " MiB";
|
|
else if (size >= 1024)
|
|
size = util.formatNumber(size / 1024, 0) + " KiB";
|
|
else size = util.formatNumber(size, 0) + " bytes";
|
|
return size;
|
|
}),
|
|
(util.bytesFromIP = function (t) {
|
|
if (-1 !== t.indexOf(".")) return util.bytesFromIPv4(t);
|
|
if (-1 !== t.indexOf(":")) return util.bytesFromIPv6(t);
|
|
else return null;
|
|
}),
|
|
(util.bytesFromIPv4 = function (t) {
|
|
if (4 !== (t = t.split(".")).length) return null;
|
|
for (var e = util.createBuffer(), n = 0; n < t.length; ++n) {
|
|
var i = parseInt(t[n], 10);
|
|
if (isNaN(i)) return null;
|
|
e.putByte(i);
|
|
}
|
|
return e.getBytes();
|
|
}),
|
|
(util.bytesFromIPv6 = function (t) {
|
|
for (
|
|
var e = 0,
|
|
n =
|
|
2 *
|
|
(8 -
|
|
(t = t.split(":").filter(function (t) {
|
|
if (0 === t.length) ++e;
|
|
return true;
|
|
})).length +
|
|
e),
|
|
i = util.createBuffer(),
|
|
o = 0;
|
|
o < 8;
|
|
++o
|
|
)
|
|
if (t[o] && 0 !== t[o].length) {
|
|
var a = util.hexToBytes(t[o]);
|
|
if (a.length < 2) i.putByte(0);
|
|
i.putBytes(a);
|
|
} else i.fillWithByte(0, n), (n = 0);
|
|
return i.getBytes();
|
|
}),
|
|
(util.bytesToIP = function (t) {
|
|
if (4 === t.length) return util.bytesToIPv4(t);
|
|
if (16 === t.length) return util.bytesToIPv6(t);
|
|
else return null;
|
|
}),
|
|
(util.bytesToIPv4 = function (t) {
|
|
if (4 !== t.length) return null;
|
|
for (var e = [], n = 0; n < t.length; ++n) e.push(t.charCodeAt(n));
|
|
return e.join(".");
|
|
}),
|
|
(util.bytesToIPv6 = function (t) {
|
|
if (16 !== t.length) return null;
|
|
for (var e = [], n = [], i = 0, o = 0; o < t.length; o += 2) {
|
|
for (
|
|
var a = util.bytesToHex(t[o] + t[o + 1]);
|
|
"0" === a[0] && "0" !== a;
|
|
|
|
)
|
|
a = a.substr(1);
|
|
if ("0" === a) {
|
|
var s = n[n.length - 1],
|
|
u = e.length;
|
|
if (!s || u !== s.end + 1) n.push({ start: u, end: u });
|
|
else if (((s.end = u), s.end - s.start > n[i].end - n[i].start))
|
|
i = n.length - 1;
|
|
}
|
|
e.push(a);
|
|
}
|
|
if (n.length > 0) {
|
|
var group = n[i];
|
|
if (group.end - group.start > 0) {
|
|
if (
|
|
(e.splice(group.start, group.end - group.start + 1, ""),
|
|
0 === group.start)
|
|
)
|
|
e.unshift("");
|
|
if (7 === group.end) e.push("");
|
|
}
|
|
}
|
|
return e.join(":");
|
|
}),
|
|
(util.estimateCores = function (t, e) {
|
|
function n(t, a, s) {
|
|
if (0 === a) {
|
|
var u = Math.floor(
|
|
t.reduce(function (t, e) {
|
|
return t + e;
|
|
}, 0) / t.length
|
|
);
|
|
return (
|
|
(util.cores = Math.max(1, u)),
|
|
URL.revokeObjectURL(o),
|
|
e(null, util.cores)
|
|
);
|
|
}
|
|
map(s, function (e, o) {
|
|
t.push(i(s, o)), n(t, a - 1, s);
|
|
});
|
|
}
|
|
function map(t, e) {
|
|
for (var n = [], i = [], a = 0; a < t; ++a) {
|
|
var worker = new Worker(o);
|
|
worker.addEventListener("message", function (o) {
|
|
if ((i.push(o.data), i.length === t)) {
|
|
for (var a = 0; a < t; ++a) n[a].terminate();
|
|
e(null, i);
|
|
}
|
|
}),
|
|
n.push(worker);
|
|
}
|
|
for (var a = 0; a < t; ++a) n[a].postMessage(a);
|
|
}
|
|
function i(t, e) {
|
|
for (var n = [], i = 0; i < t; ++i)
|
|
for (var o = e[i], overlap = (n[i] = []), a = 0; a < t; ++a)
|
|
if (i !== a) {
|
|
var s = e[a];
|
|
if (
|
|
(o.st > s.st && o.st < s.et) ||
|
|
(s.st > o.st && s.st < o.et)
|
|
)
|
|
overlap.push(a);
|
|
}
|
|
return n.reduce(function (t, overlap) {
|
|
return Math.max(t, overlap.length);
|
|
}, 0);
|
|
}
|
|
if ("function" == typeof t) (e = t), (t = {});
|
|
if (((t = t || {}), "cores" in util && !t.update))
|
|
return e(null, util.cores);
|
|
if (
|
|
"undefined" != typeof navigator &&
|
|
"hardwareConcurrency" in navigator &&
|
|
navigator.hardwareConcurrency > 0
|
|
)
|
|
return (
|
|
(util.cores = navigator.hardwareConcurrency), e(null, util.cores)
|
|
);
|
|
if ("undefined" == typeof Worker)
|
|
return (util.cores = 1), e(null, util.cores);
|
|
if ("undefined" == typeof Blob)
|
|
return (util.cores = 2), e(null, util.cores);
|
|
var o = URL.createObjectURL(
|
|
new Blob(
|
|
[
|
|
"(",
|
|
function () {
|
|
self.addEventListener("message", function (t) {
|
|
for (var e = Date.now(), et = e + 4; Date.now() < et;);
|
|
self.postMessage({ st: e, et: et });
|
|
});
|
|
}.toString(),
|
|
")()",
|
|
],
|
|
{ type: "application/javascript" }
|
|
)
|
|
);
|
|
n([], 5, 16);
|
|
});
|
|
}).call(e, n(86), n(248).setImmediate, n(41), n(42).Buffer);
|
|
},
|
|
160: function (t, e, n) {
|
|
"use strict";
|
|
function Accordion(link) {
|
|
(this.selector = ".u-accordion"),
|
|
(this.activeClass = "u-accordion-active"),
|
|
(this._paneSelector = ".u-accordion-pane"),
|
|
(this.activeSelector = "." + this.activeClass),
|
|
(this._linkSelector = ".u-accordion-link"),
|
|
(this.activeLinkClass = "active"),
|
|
(this.activeLinkSelector = "." + this.activeLinkClass),
|
|
(this._isCollapsedByDefaultSelector = ".u-collapsed-by-default"),
|
|
(this._link = link),
|
|
(this._accordion = this._link.closest(this.selector));
|
|
}
|
|
(t.exports = Accordion),
|
|
(Accordion.prototype.show = function (t) {
|
|
var link = this._link;
|
|
if (link.is(this.activeLinkSelector) && !t)
|
|
return this._removeActiveLink(), this._hidePane(link), void 0;
|
|
this._removeActiveLink(),
|
|
this._hidePane(link),
|
|
this._addActiveLink(link),
|
|
this._activatePane(link);
|
|
}),
|
|
(Accordion.prototype._removeActiveLink = function () {
|
|
var t = this._getActiveLink();
|
|
t.removeClass(this.activeLinkClass), t.attr("aria-selected", false);
|
|
}),
|
|
(Accordion.prototype._getActiveLink = function () {
|
|
return this._accordion.find(this.activeLinkSelector);
|
|
}),
|
|
(Accordion.prototype._addActiveLink = function (link) {
|
|
link.addClass(this.activeLinkClass), link.attr("aria-selected", true);
|
|
}),
|
|
(Accordion.prototype._activatePane = function (link) {
|
|
var pane;
|
|
this._accordion.find(this.activeSelector).removeClass(this.activeClass),
|
|
this._getPane(link).addClass(this.activeClass);
|
|
}),
|
|
(Accordion.prototype._getPane = function (link) {
|
|
return link.siblings(this._paneSelector);
|
|
}),
|
|
(Accordion.prototype._hidePane = function (link) {
|
|
var pane;
|
|
this._getPane(link).removeClass(this.activeClass);
|
|
}),
|
|
(Accordion.prototype.closeAll = function () {
|
|
this._accordion
|
|
.find(this._linkSelector + this.activeLinkSelector)
|
|
.removeClass(this.activeLinkClass)
|
|
.attr("aria-selected", false),
|
|
this._accordion
|
|
.find(this._paneSelector + this.activeSelector)
|
|
.removeClass(this.activeClass);
|
|
}),
|
|
(Accordion.prototype.isCollapsedByDefault = function () {
|
|
return this._accordion.is(this._isCollapsedByDefaultSelector);
|
|
});
|
|
},
|
|
180: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
(u = String.fromCharCode(128)),
|
|
(u += a.util.fillString(String.fromCharCode(0), 64)),
|
|
(f = [
|
|
1116352408, 1899447441, 3049323471, 3921009573, 961987163, 1508970993,
|
|
2453635748, 2870763221, 3624381080, 310598401, 607225278, 1426881987,
|
|
1925078388, 2162078206, 2614888103, 3248222580, 3835390401,
|
|
4022224774, 264347078, 604807628, 770255983, 1249150122, 1555081692,
|
|
1996064986, 2554220882, 2821834349, 2952996808, 3210313671,
|
|
3336571891, 3584528711, 113926993, 338241895, 666307205, 773529912,
|
|
1294757372, 1396182291, 1695183700, 1986661051, 2177026350,
|
|
2456956037, 2730485921, 2820302411, 3259730800, 3345764771,
|
|
3516065817, 3600352804, 4094571909, 275423344, 430227734, 506948616,
|
|
659060556, 883997877, 958139571, 1322822218, 1537002063, 1747873779,
|
|
1955562222, 2024104815, 2227730452, 2361852424, 2428436474,
|
|
2756734187, 3204031479, 3329325298,
|
|
]),
|
|
(l = true);
|
|
}
|
|
function o(t, e, n) {
|
|
for (
|
|
var i, o, a, s, u, l, c, h, p, m, d, v, g, y, w, b = n.length();
|
|
b >= 64;
|
|
|
|
) {
|
|
for (c = 0; c < 16; ++c) e[c] = n.getInt32();
|
|
for (; c < 64; ++c)
|
|
(i =
|
|
(((i = e[c - 2]) >>> 17) | (i << 15)) ^
|
|
((i >>> 19) | (i << 13)) ^
|
|
(i >>> 10)),
|
|
(o =
|
|
(((o = e[c - 15]) >>> 7) | (o << 25)) ^
|
|
((o >>> 18) | (o << 14)) ^
|
|
(o >>> 3)),
|
|
(e[c] = (i + e[c - 7] + o + e[c - 16]) | 0);
|
|
for (
|
|
h = t.h0,
|
|
p = t.h1,
|
|
m = t.h2,
|
|
d = t.h3,
|
|
v = t.h4,
|
|
g = t.h5,
|
|
y = t.h6,
|
|
w = t.h7,
|
|
c = 0;
|
|
c < 64;
|
|
++c
|
|
)
|
|
(a =
|
|
((h >>> 2) | (h << 30)) ^
|
|
((h >>> 13) | (h << 19)) ^
|
|
((h >>> 22) | (h << 10))),
|
|
(l = (h & p) | (m & (h ^ p))),
|
|
(i =
|
|
w +
|
|
(s =
|
|
((v >>> 6) | (v << 26)) ^
|
|
((v >>> 11) | (v << 21)) ^
|
|
((v >>> 25) | (v << 7))) +
|
|
(u = y ^ (v & (g ^ y))) +
|
|
f[c] +
|
|
e[c]),
|
|
(w = y),
|
|
(y = g),
|
|
(g = v),
|
|
(v = (d + i) >>> 0),
|
|
(d = m),
|
|
(m = p),
|
|
(p = h),
|
|
(h = (i + (o = a + l)) >>> 0);
|
|
(t.h0 = (t.h0 + h) | 0),
|
|
(t.h1 = (t.h1 + p) | 0),
|
|
(t.h2 = (t.h2 + m) | 0),
|
|
(t.h3 = (t.h3 + d) | 0),
|
|
(t.h4 = (t.h4 + v) | 0),
|
|
(t.h5 = (t.h5 + g) | 0),
|
|
(t.h6 = (t.h6 + y) | 0),
|
|
(t.h7 = (t.h7 + w) | 0),
|
|
(b -= 64);
|
|
}
|
|
}
|
|
var a = n(8);
|
|
n(56), n(12);
|
|
var s = (t.exports = a.sha256 = a.sha256 || {});
|
|
(a.md.sha256 = a.md.algorithms.sha256 = s),
|
|
(s.create = function () {
|
|
if (!l) i();
|
|
var t = null,
|
|
e = a.util.createBuffer(),
|
|
n = new Array(64),
|
|
s = {
|
|
algorithm: "sha256",
|
|
blockLength: 64,
|
|
digestLength: 32,
|
|
messageLength: 0,
|
|
fullMessageLength: null,
|
|
messageLengthSize: 8,
|
|
start: function () {
|
|
(s.messageLength = 0),
|
|
(s.fullMessageLength = s.messageLength64 = []);
|
|
for (var n = s.messageLengthSize / 4, i = 0; i < n; ++i)
|
|
s.fullMessageLength.push(0);
|
|
return (
|
|
(e = a.util.createBuffer()),
|
|
(t = {
|
|
h0: 1779033703,
|
|
h1: 3144134277,
|
|
h2: 1013904242,
|
|
h3: 2773480762,
|
|
h4: 1359893119,
|
|
h5: 2600822924,
|
|
h6: 528734635,
|
|
h7: 1541459225,
|
|
}),
|
|
s
|
|
);
|
|
},
|
|
};
|
|
return (
|
|
s.start(),
|
|
(s.update = function (i, u) {
|
|
if ("utf8" === u) i = a.util.encodeUtf8(i);
|
|
var l = i.length;
|
|
(s.messageLength += l), (l = [(l / 4294967296) >>> 0, l >>> 0]);
|
|
for (var f = s.fullMessageLength.length - 1; f >= 0; --f)
|
|
(s.fullMessageLength[f] += l[1]),
|
|
(l[1] = l[0] + ((s.fullMessageLength[f] / 4294967296) >>> 0)),
|
|
(s.fullMessageLength[f] = s.fullMessageLength[f] >>> 0),
|
|
(l[0] = (l[1] / 4294967296) >>> 0);
|
|
if ((e.putBytes(i), o(t, n, e), e.read > 2048 || 0 === e.length()))
|
|
e.compact();
|
|
return s;
|
|
}),
|
|
(s.digest = function () {
|
|
var i = a.util.createBuffer();
|
|
i.putBytes(e.bytes());
|
|
var l,
|
|
f =
|
|
(s.fullMessageLength[s.fullMessageLength.length - 1] +
|
|
s.messageLengthSize) &
|
|
(s.blockLength - 1),
|
|
c,
|
|
h;
|
|
i.putBytes(u.substr(0, s.blockLength - f));
|
|
for (
|
|
var p = 8 * s.fullMessageLength[0], m = 0;
|
|
m < s.fullMessageLength.length - 1;
|
|
++m
|
|
)
|
|
(p += h =
|
|
((c = 8 * s.fullMessageLength[m + 1]) / 4294967296) >>> 0),
|
|
i.putInt32(p >>> 0),
|
|
(p = c >>> 0);
|
|
i.putInt32(p);
|
|
var v = {
|
|
h0: t.h0,
|
|
h1: t.h1,
|
|
h2: t.h2,
|
|
h3: t.h3,
|
|
h4: t.h4,
|
|
h5: t.h5,
|
|
h6: t.h6,
|
|
h7: t.h7,
|
|
};
|
|
o(v, n, i);
|
|
var g = a.util.createBuffer();
|
|
return (
|
|
g.putInt32(v.h0),
|
|
g.putInt32(v.h1),
|
|
g.putInt32(v.h2),
|
|
g.putInt32(v.h3),
|
|
g.putInt32(v.h4),
|
|
g.putInt32(v.h5),
|
|
g.putInt32(v.h6),
|
|
g.putInt32(v.h7),
|
|
g
|
|
);
|
|
}),
|
|
s
|
|
);
|
|
});
|
|
var u = null,
|
|
l = false,
|
|
f = null;
|
|
},
|
|
189: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
(this.hint = null), (this.animations = []);
|
|
}
|
|
t.exports = i;
|
|
var o = null;
|
|
(i.instance = function instance() {
|
|
if (!o) o = new i();
|
|
return o;
|
|
}),
|
|
(i.prototype.createAnimation = function t(e) {
|
|
for (var n = 0; n < this.animations.length; n++)
|
|
if (this.animations[n].isMatch(e))
|
|
return this.animations[n].create(e, this.hint);
|
|
return null;
|
|
}),
|
|
(i.prototype.setHint = function t(e) {
|
|
this.hint = e;
|
|
}),
|
|
(i.prototype.registerAnimation = function (animation) {
|
|
this.animations.push(animation);
|
|
}),
|
|
(window.AnimationFactory = i);
|
|
},
|
|
190: function (t, e, n) {
|
|
"use strict";
|
|
function i(t, e) {
|
|
if (!t) throw new Error("animationInfo is null or undefined");
|
|
if (
|
|
((this.info = t),
|
|
(this.hint = e),
|
|
(this.animatedClass = ["animated"]),
|
|
(this.backstageClass = ["backstage"]),
|
|
(this.animationInClass = this.getAnimationClass()),
|
|
this.isInOutAnimation())
|
|
)
|
|
this.animationOutClass = this.getAnimationOutClass();
|
|
(this._reqestId = null),
|
|
(this._timeoutId = null),
|
|
(this._animationInTimeoutId = null),
|
|
(this._handleAnimationEnd = this._handleAnimationEnd.bind(this)),
|
|
(this._playing = null),
|
|
(this._playNext = null),
|
|
(this._playNextDuration = null);
|
|
}
|
|
function o(t) {
|
|
if (!t) return null;
|
|
if (t < l) t = l;
|
|
return t + "ms";
|
|
}
|
|
function a(t, e) {
|
|
if ((e = o(e))) t.style["animation-duration"] = e;
|
|
}
|
|
function s(t) {
|
|
switch (t) {
|
|
case "Down":
|
|
return "Up";
|
|
case "Up":
|
|
return "Down";
|
|
default:
|
|
return t;
|
|
}
|
|
}
|
|
var u = n(270);
|
|
t.exports = i;
|
|
var l = 100,
|
|
f = 500,
|
|
c = "In",
|
|
h = "Out";
|
|
(i.isMatch = function () {
|
|
return true;
|
|
}),
|
|
(i.create = function (t, e) {
|
|
return new i(t, e);
|
|
}),
|
|
(i.prototype._handleAnimationEnd = function t(e) {
|
|
if (e.target === this.info.element) {
|
|
if (
|
|
((this._playing = null),
|
|
a(this.info.element, this.info.duration),
|
|
this.info.element.classList.contains(this.animationInClass))
|
|
)
|
|
this.info.element.classList.remove(this.animationInClass),
|
|
this.info.element.classList.add(
|
|
this.animationInClass + "-played"
|
|
);
|
|
else
|
|
this.info.element.classList.remove(
|
|
this.animationInClass + "-played"
|
|
);
|
|
if (this._playNext) {
|
|
var n = this._playNext,
|
|
i = this._playNextDuration;
|
|
(this._playNext = null),
|
|
(this._playNextDuration = null),
|
|
this._play(n, i);
|
|
}
|
|
}
|
|
}),
|
|
(i.prototype.subscribe = function t() {
|
|
this.info.element.addEventListener(
|
|
"animationend",
|
|
this._handleAnimationEnd
|
|
);
|
|
}),
|
|
(i.prototype.unsubscribe = function t() {
|
|
this.info.element.removeEventListener(
|
|
"animationend",
|
|
this._handleAnimationEnd
|
|
);
|
|
}),
|
|
(i.prototype.init = function init() {
|
|
if (this.hint) this.hint.hintBrowser(this.info);
|
|
this.subscribe(), this.reset();
|
|
}),
|
|
(i.prototype.clear = function t() {
|
|
if (this.info) {
|
|
if (this.backstageClass)
|
|
this.info.element.classList.remove.apply(
|
|
this.info.element.classList,
|
|
this.backstageClass
|
|
);
|
|
if (this.animatedClass)
|
|
this.info.element.classList.remove.apply(
|
|
this.info.element.classList,
|
|
this.animatedClass
|
|
);
|
|
if (this.animationInClass)
|
|
this.info.element.classList.remove(this.animationInClass);
|
|
if (this.outAnimatedClass)
|
|
this.info.element.classList.remove(this.animationOutClass);
|
|
if (((this.info.element.style["animation-duration"] = ""), this.hint))
|
|
this.hint.removeHint(this.info);
|
|
if (this._animationInTimeoutId)
|
|
clearTimeout(this._animationInTimeoutId),
|
|
(this._animationInTimeoutId = null);
|
|
(this._playing = null), (this._playNext = null), this.unsubscribe();
|
|
}
|
|
}),
|
|
(i.prototype.requestAnimationFrame = function t(e) {
|
|
return u.requestAnimationFrame(e);
|
|
}),
|
|
(i.prototype.cancelAnimationFrame = function t(id) {
|
|
if (window.cancelAnimationFrame)
|
|
return window.cancelAnimationFrame(id), void 0;
|
|
if (window.mozCancelAnimationFrame) window.mozCancelAnimationFrame(id);
|
|
}),
|
|
(i.prototype.getAnimationClass = function t() {
|
|
if (!this.info) return null;
|
|
var e = this.info.name;
|
|
if (this.info.direction) e += this.info.direction;
|
|
return e;
|
|
}),
|
|
(i.prototype.getAnimationOutClass = function t() {
|
|
if (!this.info) return null;
|
|
var e = this.info.name;
|
|
if (this.isInOutAnimation()) e = e.slice(0, 0 - c.length) + h;
|
|
if (this.info.direction) e += s(this.info.direction);
|
|
return e;
|
|
}),
|
|
(i.prototype.isInOutAnimation = function t() {
|
|
if (!this.info || !this.info.name || !this.info.animationOut)
|
|
return false;
|
|
else
|
|
return this.info.name.indexOf(c) + c.length === this.info.name.length;
|
|
}),
|
|
(i.prototype.start = function t() {
|
|
if (this.info) {
|
|
var e = this.info.delay,
|
|
n = function () {
|
|
(this._animationInTimeoutId = null),
|
|
this._play(this.animationInClass);
|
|
}.bind(this);
|
|
if (this._animationInTimeoutId)
|
|
clearTimeout(this._animationInTimeoutId);
|
|
if (!e) return n(), void 0;
|
|
this._animationInTimeoutId = setTimeout(n, e);
|
|
}
|
|
}),
|
|
(i.prototype.startOut = function t() {
|
|
if (this.info)
|
|
if (this.animationOutClass)
|
|
if (this._animationInTimeoutId)
|
|
return (
|
|
clearInterval(this._animationInTimeoutId),
|
|
(this._animationInTimeoutId = null),
|
|
void 0
|
|
);
|
|
else return this._play(this.animationOutClass, f), void 0;
|
|
}),
|
|
(i.prototype._play = function t(animation, e) {
|
|
if (!animation) animation = this.animationInClass;
|
|
if (e) a(this.info.element, e);
|
|
if (this._playing === animation) return (this._playNext = null), void 0;
|
|
if (this._playing)
|
|
return (
|
|
(this._playNext = animation), (this._playNextDuration = e), void 0
|
|
);
|
|
if (((this._playing = animation), this._reqestId))
|
|
this.cancelAnimationFrame(this._reqestId);
|
|
this._reqestId = this.requestAnimationFrame(
|
|
function () {
|
|
if (((this._reqestId = null), this.backstageClass))
|
|
this.info.element.classList.remove.apply(
|
|
this.info.element.classList,
|
|
this.backstageClass
|
|
);
|
|
if (this.animationOutClass)
|
|
this.info.element.classList.remove(this.animationOutClass);
|
|
if (this.animationInClass)
|
|
this.info.element.classList.remove(this.animationInClass);
|
|
if (animation) this.info.element.classList.add(animation);
|
|
}.bind(this)
|
|
);
|
|
}),
|
|
(i.prototype.reset = function t() {
|
|
if (this.info) {
|
|
var e = this.info.duration;
|
|
if (
|
|
(a(this.info.element, e),
|
|
(this._playing = null),
|
|
(this._playNext = null),
|
|
this.backstageClass)
|
|
)
|
|
this.info.element.classList.add.apply(
|
|
this.info.element.classList,
|
|
this.backstageClass
|
|
);
|
|
if (this.animatedClass)
|
|
this.info.element.classList.add.apply(
|
|
this.info.element.classList,
|
|
this.animatedClass
|
|
);
|
|
}
|
|
}),
|
|
(i.prototype.needOutAnimation = function t() {
|
|
if (!this.isInOutAnimation()) return false;
|
|
if (this._animationInTimeoutId) return true;
|
|
else
|
|
return (
|
|
(this.info.element.classList.contains(this.animationInClass) ||
|
|
this.info.element.classList.contains(
|
|
this.animationInClass + "-played"
|
|
)) &&
|
|
!this.info.element.classList.contains(this.backstageClass[0])
|
|
);
|
|
}),
|
|
(i.prototype.getTime = function t() {
|
|
if (!this.info) return 0;
|
|
var e = this.info.duration,
|
|
n = this.info.delay;
|
|
if (isNaN(n)) n = 0;
|
|
return n + e;
|
|
}),
|
|
(i.prototype.getOutTime = function t() {
|
|
if (!this.info || !this.isInOutAnimation()) return 0;
|
|
else return f;
|
|
});
|
|
},
|
|
191: function (t, e, n) {
|
|
"use strict";
|
|
function CountdownUpdater(t) {
|
|
(this.$dom = t), (this.countdownCommon = new CountdownCommon(t));
|
|
}
|
|
t.exports = CountdownUpdater;
|
|
var CountdownCommon = n(32);
|
|
(CountdownUpdater.prototype.startUpdate = function (t) {
|
|
var e = this.getUpdateTimeout();
|
|
if (e) this.update(t, true), setInterval(this.update.bind(this), e, t);
|
|
}),
|
|
(CountdownUpdater.prototype.getUpdateTimeout = function () {
|
|
if (this.countdownCommon.getAfterCountFinished()) return 0;
|
|
var countdownType = this.countdownCommon.getType();
|
|
if ("to-date" === countdownType || "to-time" === countdownType)
|
|
return 350;
|
|
if ("to-number" === countdownType) {
|
|
var t = this.countdownCommon.getFrequency(),
|
|
e = CountdownCommon.timeStringToMilliseconds(t);
|
|
return (e = Math.max(e, 0)), (e = Math.min(e, 350));
|
|
}
|
|
return 0;
|
|
}),
|
|
(CountdownUpdater.prototype.getAnimationProps = function (t, e) {
|
|
if (e) return { animation: "none" };
|
|
else
|
|
return {
|
|
animation:
|
|
("runtime" === t && this.countdownCommon.getCountAnimation()) ||
|
|
"none",
|
|
animationSpeed: this.getUpdateTimeout(),
|
|
};
|
|
}),
|
|
(CountdownUpdater.prototype.update = function (t, e) {
|
|
if (!this.countdownCommon.getAfterCountFinished()) {
|
|
var countdownType = this.countdownCommon.getType();
|
|
if ("to-date" === countdownType || "to-time" === countdownType)
|
|
this.updateDateAndTime(t, e);
|
|
if ("to-number" === countdownType) this.updateNumber(t, e);
|
|
}
|
|
}),
|
|
(CountdownUpdater.prototype.updateDateAndTime = function (t, e) {
|
|
var n = this.countdownCommon.getDate(),
|
|
diff = this.getTimeDiff(n);
|
|
if (!this.afterCount(diff, t)) {
|
|
var props = this.getAnimationProps(t, e);
|
|
this.countdownCommon.setValue("years", diff.years, false, props),
|
|
this.countdownCommon.setValue("days", diff.days, false, props),
|
|
this.countdownCommon.setValue("hours", diff.hours, false, props),
|
|
this.countdownCommon.setValue(
|
|
"minutes",
|
|
diff.minutes,
|
|
false,
|
|
props
|
|
),
|
|
this.countdownCommon.setValue(
|
|
"seconds",
|
|
diff.seconds,
|
|
false,
|
|
props
|
|
),
|
|
this.countdownCommon.showLabel("years", !!diff.years),
|
|
this.countdownCommon.showLabel("days", !!diff.days);
|
|
}
|
|
}),
|
|
(CountdownUpdater.prototype.updateNumber = function (t, e) {
|
|
var n = this.countdownCommon.getNumber(),
|
|
i = this.countdownCommon.getStartTime(),
|
|
o = this.countdownCommon.getFrequency(),
|
|
diff = this.countdownCommon.calcNumber(n, i, o);
|
|
if ("per-visitor" === this.countdownCommon.getFor()) {
|
|
var a = this.countdownCommon.getTimerId();
|
|
(i = this.getStartDate(a)),
|
|
(diff = this.countdownCommon.calcNumber(n, i, o));
|
|
}
|
|
if (!this.afterCount(diff, t)) {
|
|
var props = this.getAnimationProps(t, e);
|
|
this.countdownCommon.setValue("numbers", diff, false, props);
|
|
}
|
|
}),
|
|
(CountdownUpdater.prototype.getTimeDiff = function (t) {
|
|
if ("everyone" === this.countdownCommon.getFor())
|
|
return this.countdownCommon.timeDiff(t);
|
|
var e = this.getStartDate(),
|
|
n = this.countdownCommon.getTimeLeft();
|
|
return (
|
|
(t = this.countdownCommon.parseTime(n, e)),
|
|
this.countdownCommon.timeDiff(t)
|
|
);
|
|
}),
|
|
(CountdownUpdater.prototype.getStartDate = function () {
|
|
var t = this.countdownCommon.getTimerKey(),
|
|
e = localStorage.getItem(t);
|
|
if (e) return new Date(e);
|
|
var n = new Date();
|
|
return localStorage.setItem(t, n.toUTCString()), n;
|
|
}),
|
|
(CountdownUpdater.prototype.afterCount = function (diff, t) {
|
|
var e = this.countdownCommon.getDirection(),
|
|
n = this.countdownCommon.getAfterCount();
|
|
if (
|
|
((t = t || ""),
|
|
"none" !== n && "down" === e && CountdownCommon.isEmptyDiff(diff))
|
|
) {
|
|
if ("message" === n) this.showMessage();
|
|
if ("redirect" === n)
|
|
if (
|
|
(this.$dom.find(".u-countdown-message").text("Redirecting..."),
|
|
this.showMessage(),
|
|
"preview" !== t)
|
|
) {
|
|
var i = this.countdownCommon.getRedirectUrl();
|
|
window.location.href = i;
|
|
}
|
|
if ("preview" !== t) this.countdownCommon.setAfterCountFinished();
|
|
return true;
|
|
}
|
|
return false;
|
|
}),
|
|
(CountdownUpdater.prototype.showMessage = function () {
|
|
if (this.$dom.find(".u-countdown-message").is(".u-hidden"))
|
|
this.$dom.find(".u-countdown-wrapper").addClass("u-invisible"),
|
|
this.$dom.find(".u-countdown-message").removeClass("u-hidden");
|
|
}),
|
|
(CountdownUpdater.prototype.hideMessage = function () {
|
|
if (this.$dom.find(".u-countdown-message").not(".u-hidden"))
|
|
this.$dom.find(".u-countdown-wrapper").removeClass("u-invisible"),
|
|
this.$dom.find(".u-countdown-message").addClass("u-hidden");
|
|
}),
|
|
(CountdownUpdater.findAll = function () {
|
|
return $(".u-countdown");
|
|
});
|
|
},
|
|
195: function (t, e, n) {
|
|
"use strict";
|
|
function Dialog(t) {
|
|
(this._openClass = "u-dialog-open"),
|
|
(this._dialogBlockClass = "u-dialog-block"),
|
|
(this._dialogBlockSelector = "." + this._dialogBlockClass),
|
|
(this._dialog = t.closest(this._dialogBlockSelector));
|
|
}
|
|
function i(t) {
|
|
if (!window._responsive) return false;
|
|
var e = t.find(".u-dialog"),
|
|
n = window._responsive.mode || "XL";
|
|
return e.is(".u-hidden, .u-hidden-" + n.toLowerCase());
|
|
}
|
|
(t.exports = Dialog),
|
|
(Dialog.prototype.open = function (t) {
|
|
this._dialog.each(
|
|
function (e, block) {
|
|
var n = $(block);
|
|
if (!i(n)) {
|
|
if ((n.addClass(this._openClass), "function" == typeof t)) t(n);
|
|
n.trigger("opened.np.dialog", [this]);
|
|
}
|
|
}.bind(this)
|
|
);
|
|
}),
|
|
(Dialog.prototype.close = function () {
|
|
this._dialog.removeClass(this._openClass),
|
|
this._dialog.trigger("closed.np.dialog", [this]);
|
|
}),
|
|
(Dialog.prototype.getInterval = function () {
|
|
return this._dialog.attr("data-dialog-show-interval") || 3e3;
|
|
});
|
|
},
|
|
248: function (t, e, n) {
|
|
"use strict";
|
|
(function (t) {
|
|
function i(id, t) {
|
|
(this._id = id), (this._clearFn = t);
|
|
}
|
|
var o =
|
|
(void 0 !== t && t) || ("undefined" != typeof self && self) || window,
|
|
a = Function.prototype.apply;
|
|
(e.setTimeout = function () {
|
|
return new i(a.call(setTimeout, o, arguments), clearTimeout);
|
|
}),
|
|
(e.setInterval = function () {
|
|
return new i(a.call(setInterval, o, arguments), clearInterval);
|
|
}),
|
|
(e.clearTimeout = e.clearInterval =
|
|
function (t) {
|
|
if (t) t.close();
|
|
}),
|
|
(i.prototype.unref = i.prototype.ref = function () { }),
|
|
(i.prototype.close = function () {
|
|
this._clearFn.call(o, this._id);
|
|
}),
|
|
(e.enroll = function (t, e) {
|
|
clearTimeout(t._idleTimeoutId), (t._idleTimeout = e);
|
|
}),
|
|
(e.unenroll = function (t) {
|
|
clearTimeout(t._idleTimeoutId), (t._idleTimeout = -1);
|
|
}),
|
|
(e._unrefActive = e.active =
|
|
function (t) {
|
|
clearTimeout(t._idleTimeoutId);
|
|
var e = t._idleTimeout;
|
|
if (e >= 0)
|
|
t._idleTimeoutId = setTimeout(function e() {
|
|
if (t._onTimeout) t._onTimeout();
|
|
}, e);
|
|
}),
|
|
n(381),
|
|
(e.setImmediate =
|
|
("undefined" != typeof self && self.setImmediate) ||
|
|
(void 0 !== t && t.setImmediate) ||
|
|
(this && this.setImmediate)),
|
|
(e.clearImmediate =
|
|
("undefined" != typeof self && self.clearImmediate) ||
|
|
(void 0 !== t && t.clearImmediate) ||
|
|
(this && this.clearImmediate));
|
|
}).call(e, n(41));
|
|
},
|
|
2655: function (t, e, n) {
|
|
"use strict";
|
|
var FormMessage = (t.exports = {}),
|
|
i = n(10);
|
|
(FormMessage.showSuccess = function t(form) {
|
|
form.trigger("reset");
|
|
var e = form.find(".u-form-send-success"),
|
|
n = e.find(".u-form-send-message-close");
|
|
if (!n.length)
|
|
(n = i('<a href="#" class="u-form-send-message-close">x</a>')),
|
|
e.append(n);
|
|
e.show(),
|
|
n.one("click", function (t) {
|
|
t.preventDefault(), e.hide();
|
|
}),
|
|
form.find('input[type="submit"]').prop("disabled", false);
|
|
}),
|
|
(FormMessage.showError = function t(form, e, n, o) {
|
|
var a = e
|
|
? form.find(".u-form-send-error").clone()
|
|
: form.find(".u-form-send-error");
|
|
if (e) {
|
|
if (n)
|
|
if (560 === n && o)
|
|
e =
|
|
"Unable to submit the Contact Form, as the submission email is not verified.\n" +
|
|
"</br></br>" +
|
|
"If you are a site administrator, please open your inbox and confirm the " +
|
|
o +
|
|
" email in the message. Make sure also to check your spam folder.";
|
|
a.html(e), form.find(".u-form-send-error").parent().append(a);
|
|
}
|
|
var s = a.find(".u-form-send-message-close");
|
|
if (!s.length)
|
|
(s = i('<a href="#" class="u-form-send-message-close">x</a>')),
|
|
a.append(s);
|
|
s.one("click", function (t) {
|
|
if ((t.preventDefault(), a.hide(), e)) a.remove();
|
|
}),
|
|
a.show(),
|
|
form.find('input[type="submit"]').prop("disabled", false);
|
|
});
|
|
},
|
|
270: function (t, e, n) {
|
|
"use strict";
|
|
var i;
|
|
t.exports.requestAnimationFrame = function t(e) {
|
|
if (window.requestAnimationFrame) return window.requestAnimationFrame(e);
|
|
if (window.mozRequestAnimationFrame)
|
|
return window.mozRequestAnimationFrame(e);
|
|
if (window.webkitRequestAnimationFrame)
|
|
return window.webkitRequestAnimationFrame(e);
|
|
if (window.msRequestAnimationFrame)
|
|
return window.msRequestAnimationFrame(e);
|
|
else return e(), void 0;
|
|
};
|
|
},
|
|
271: function (t, e, n) {
|
|
"use strict";
|
|
function i(t, section) {
|
|
if (
|
|
((this.element = t),
|
|
(this.section = section),
|
|
(this.name = t.getAttribute("data-animation-name")),
|
|
(this.event = "scroll"),
|
|
(this.durationRaw = t.getAttribute("data-animation-duration")),
|
|
(this.duration = Number(this.durationRaw)),
|
|
isNaN(this.duration) || !isFinite(this.duration) || this.duration < 0)
|
|
)
|
|
this.duration = 0;
|
|
var e = t.getAttribute("data-animation-event");
|
|
if (e) this.event = e;
|
|
if (
|
|
((this.delayRaw = t.getAttribute("data-animation-delay")),
|
|
(this.delay = 0),
|
|
this.delayRaw)
|
|
)
|
|
if (
|
|
((this.delay = Number(this.delayRaw)),
|
|
isNaN(this.delay) || !isFinite(this.delay) || this.delay < 0)
|
|
)
|
|
this.delay = 0;
|
|
var n = t.getAttribute("data-animation-cycle");
|
|
if (n) if (((n = Number(n)), !isNaN(n))) this.animationCycle = n;
|
|
var i = t.getAttribute("data-animation-direction");
|
|
if (i && "customAnimationIn" !== this.name) this.direction = i;
|
|
(this.animationOut =
|
|
!t.hasAttribute("data-animation-out") ||
|
|
parseFloat(t.getAttribute("data-animation-out"))),
|
|
(this.infinite = t.classList.contains("infinite"));
|
|
}
|
|
(t.exports = i), (window.AnimationInfo = i);
|
|
},
|
|
273: function (t, e, n) {
|
|
"use strict";
|
|
function CountdownAnimate(t) {
|
|
if (
|
|
((this.$dom = t),
|
|
(this.$html = this.$dom.find(".counter-animation")),
|
|
!this.$html.length)
|
|
) {
|
|
var e = this.$dom.text();
|
|
(this.$html = $(
|
|
'<div class="counter-animation" style="display: none;"></div>'
|
|
)),
|
|
this.$html.append('<div class="counter-wrapper"></div>'),
|
|
this.$html
|
|
.find(".counter-wrapper")
|
|
.append('<div class="counter-html"></div>'),
|
|
this.$html
|
|
.find(".counter-html")
|
|
.append($('<div class="old-val"></div>')),
|
|
this.$html
|
|
.find(".counter-html")
|
|
.append($('<div class="new-val"></div>')),
|
|
this.$dom.empty(),
|
|
this.$dom.append($('<span class="start-val"></span>').text(e)),
|
|
this.$dom.append(this.$html);
|
|
}
|
|
this.onResize(),
|
|
$(window).on(
|
|
"resize",
|
|
function () {
|
|
this.onResize();
|
|
}.bind(this)
|
|
);
|
|
}
|
|
(t.exports = CountdownAnimate),
|
|
(CountdownAnimate.prototype.rollNumber = function (t, props) {
|
|
if (!this.$dom.is(".updating")) {
|
|
this.$dom.addClass("updating");
|
|
var e = this.getOldVal(),
|
|
n = this.$dom.find(".start-val"),
|
|
i = this.$dom.find(".counter-animation"),
|
|
o = 350;
|
|
if (props.animationSpeed)
|
|
o = props.animationSpeed > 20 ? props.animationSpeed - 20 : 0;
|
|
this.$html.find(".old-val").text(e),
|
|
this.$html.find(".new-val").text(t),
|
|
this.$html.find(".counter-html").css("top", 0),
|
|
requestAnimationFrame(
|
|
function () {
|
|
n.css("display", "none"), i.css("display", "flex");
|
|
}.bind(this)
|
|
),
|
|
this.$html.find(".counter-html").animate(
|
|
{ top: -this.height + "px" },
|
|
o,
|
|
"swing",
|
|
function () {
|
|
requestAnimationFrame(
|
|
function () {
|
|
n.text(t),
|
|
n.css("display", "inline-block"),
|
|
i.css("display", "none"),
|
|
this.$dom.removeClass("updating");
|
|
}.bind(this)
|
|
);
|
|
}.bind(this)
|
|
);
|
|
}
|
|
}),
|
|
(CountdownAnimate.prototype.onResize = function () {
|
|
(this.height = this.$dom.height()),
|
|
this.$html.find(".counter-wrapper").css("height", this.height + "px");
|
|
}),
|
|
(CountdownAnimate.prototype.getOldVal = function () {
|
|
return this.$dom.find(".start-val").text();
|
|
});
|
|
},
|
|
275: function (t, e, n) {
|
|
"use strict";
|
|
function TabsControl(t) {
|
|
(this.tabsSelector = ".u-tabs"),
|
|
(this.activeClass = "u-tab-active"),
|
|
(this.activeSelector = "." + this.activeClass),
|
|
(this.activeLinkClass = "active"),
|
|
(this.activeLinkSelector = "." + this.activeLinkClass),
|
|
(this.tabListSelector = ".u-tab-list"),
|
|
(this.tabContentSelector = ".u-tab-content"),
|
|
(this.tabLinkSelector = ".u-tab-link"),
|
|
(this.tabPaneSelector = ".u-tab-pane"),
|
|
(this._tabLink = this._getLink(t)),
|
|
(this._tabList = this._tabLink.closest(this.tabListSelector)),
|
|
(this._tabContent = this._tabLink
|
|
.closest(this.tabsSelector)
|
|
.children(this.tabContentSelector));
|
|
}
|
|
(TabsControl.prototype.show = function () {
|
|
var link = this._tabLink;
|
|
if (!link.is(this.activeLinkSelector))
|
|
this._removeActiveLink(),
|
|
this._addActiveLink(link),
|
|
this._activateTabPane(link);
|
|
}),
|
|
(TabsControl.prototype._getLink = function (t) {
|
|
if (t.is(this.tabPaneSelector)) return this._findLinkByPane(t);
|
|
else
|
|
return t.is(this.tabLinkSelector)
|
|
? t
|
|
: t.children(this.tabLinkSelector);
|
|
}),
|
|
(TabsControl.prototype._findLinkByPane = function (pane) {
|
|
var t = pane.attr("aria-labelledby"),
|
|
tabList;
|
|
return pane
|
|
.closest(this.tabsSelector)
|
|
.children(this.tabListSelector)
|
|
.find("#" + t);
|
|
}),
|
|
(TabsControl.prototype._removeActiveLink = function () {
|
|
var t = this._getActiveLink();
|
|
t.removeClass(this.activeLinkClass), t.attr("aria-selected", false);
|
|
}),
|
|
(TabsControl.prototype._getActiveLink = function () {
|
|
return this._tabList.find(this.activeLinkSelector);
|
|
}),
|
|
(TabsControl.prototype._addActiveLink = function (link) {
|
|
link.addClass(this.activeLinkClass), link.attr("aria-selected", true);
|
|
}),
|
|
(TabsControl.prototype._activateTabPane = function (link) {
|
|
var t, e;
|
|
this._tabContent
|
|
.children(this.activeSelector)
|
|
.removeClass(this.activeClass),
|
|
this.getTabPane(link).addClass(this.activeClass);
|
|
}),
|
|
(TabsControl.prototype.getTabPane = function (t) {
|
|
var link,
|
|
e = this._getLink(t).attr("href");
|
|
return this._tabContent.children(e);
|
|
}),
|
|
(TabsControl.prototype.getTabLink = function () {
|
|
return this._tabLink;
|
|
}),
|
|
(TabsControl.prototype.removeId = function () {
|
|
this._tabList.find(this.tabLinkSelector).removeAttr("id"),
|
|
this._tabContent.children().removeAttr("id");
|
|
}),
|
|
(t.exports = TabsControl),
|
|
(window.TabsControl = TabsControl);
|
|
},
|
|
298: function (t, e, n) {
|
|
"use strict";
|
|
function HorizontalLayoutSlider(slider, t) {
|
|
if (slider && slider.length) {
|
|
var e = slider.children(".u-gallery-inner, .u-repeater");
|
|
if (e.length) {
|
|
this.viewport = e;
|
|
var n = slider.children(".u-gallery-nav");
|
|
if (n.length) {
|
|
if (
|
|
((this.controls = n),
|
|
(this.data = {
|
|
offset: 0,
|
|
width: 0,
|
|
scrollWidth: 0,
|
|
maxOffset: 0,
|
|
}),
|
|
t)
|
|
)
|
|
(this._onScroll = this.onScroll.bind(this)),
|
|
(this._onlazyloaded = this.onlazyloaded.bind(this)),
|
|
this.viewport.scroll(this._onScroll),
|
|
this.viewport.find("img.lazyload").each(
|
|
function (t, e) {
|
|
e.onload = this._onlazyloaded;
|
|
}.bind(this)
|
|
);
|
|
if ((this.updateInnerData(), t)) this.updateControls();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
(t.exports = HorizontalLayoutSlider),
|
|
(HorizontalLayoutSlider.prototype.onScroll = function () {
|
|
this.updateControls();
|
|
}),
|
|
(HorizontalLayoutSlider.prototype.onlazyloaded = function t() {
|
|
this.updateInnerData(), this.updateControls();
|
|
}),
|
|
(HorizontalLayoutSlider.prototype.updateControls = function () {
|
|
this.updateOffset();
|
|
var data = this.data;
|
|
this.controls.each(function () {
|
|
var t = $(this),
|
|
state = t.hasClass("u-gallery-nav-next")
|
|
? data.offset >= data.maxOffset - 1
|
|
: data.offset <= 0;
|
|
t.toggleClass("u-hidden", state);
|
|
});
|
|
}),
|
|
(HorizontalLayoutSlider.prototype.updateOffset = function () {
|
|
this.data.offset = this.viewport.scrollLeft();
|
|
}),
|
|
(HorizontalLayoutSlider.prototype.updateInnerData = function () {
|
|
if (this.data && this.viewport && this.viewport[0]) {
|
|
(this.data.scrollWidth = this.viewport[0].scrollWidth),
|
|
(this.data.width = this.viewport.innerWidth());
|
|
var t = this.viewport.scrollLeft();
|
|
this.scrollToEnd(),
|
|
(this.data.maxOffset = this.viewport.scrollLeft()),
|
|
this.viewport.scrollLeft(t);
|
|
}
|
|
}),
|
|
(HorizontalLayoutSlider.prototype.navigate = function (t) {
|
|
if (!t.hasClass("u-hidden") && this.viewport) {
|
|
this.updateInnerData(), this.updateOffset();
|
|
var e = this.data.offset,
|
|
n = this.data.width - 50,
|
|
i = 0.3 * this.data.width,
|
|
o = this.viewport
|
|
.children()
|
|
.toArray()
|
|
.map(function (t) {
|
|
return e + Math.round($(t).position().left);
|
|
});
|
|
o.push(this.data.maxOffset + this.data.width);
|
|
var a = function (t) {
|
|
return o.reduce(function (e, n) {
|
|
return Math.abs(n - t) < Math.abs(e - t) ? n : e;
|
|
});
|
|
};
|
|
if (t.hasClass("u-gallery-nav-next")) {
|
|
if (
|
|
((e = a(e + n) - 1),
|
|
this.data.scrollWidth - (e + this.data.width) < i)
|
|
)
|
|
e = this.data.maxOffset + i;
|
|
} else if (e > 0)
|
|
if ((e = a(e + this.data.width - n) - this.data.width - 1) < i)
|
|
e = 0;
|
|
this.viewport.animate(
|
|
{ scrollLeft: e },
|
|
500 * (Math.abs(this.data.offset - e) / n),
|
|
"swing"
|
|
);
|
|
}
|
|
}),
|
|
(HorizontalLayoutSlider.prototype.scrollToEnd = function () {
|
|
if (this.viewport) this.viewport.scrollLeft(this.data.scrollWidth);
|
|
}),
|
|
(window._npHorizontalLayoutSlider = HorizontalLayoutSlider);
|
|
},
|
|
299: function (t, e, n) {
|
|
"use strict";
|
|
var i = (t.exports = function t() {
|
|
(this.expr = null), (this.tokens = []);
|
|
});
|
|
(i.prototype.replace = function replace(t, e) {
|
|
(t = t.toUpperCase()),
|
|
(this.tokens = this.getTokens(t, e).sort(function (t, e) {
|
|
return e.length - t.length;
|
|
}));
|
|
for (var n = 0; n < this.tokens.length; n++)
|
|
t = t
|
|
.split(this.tokens[n].toUpperCase())
|
|
.join(" " + e[this.tokens[n]] + " ");
|
|
return (this.expr = t), this;
|
|
}),
|
|
(i.prototype.getTokens = function t(e, n) {
|
|
return (
|
|
(e = e.toUpperCase()),
|
|
Object.keys(n)
|
|
.filter(function (t) {
|
|
return /^[a-zA-Z_$][\w$-]*$/.test(t);
|
|
})
|
|
.filter(function (t) {
|
|
return e.includes(t.toUpperCase());
|
|
})
|
|
);
|
|
});
|
|
},
|
|
32: function (t, e, n) {
|
|
"use strict";
|
|
function CountdownCommon(t) {
|
|
this.$dom = t;
|
|
}
|
|
t.exports = CountdownCommon;
|
|
var CountdownAnimate = n(273);
|
|
(CountdownCommon.prototype.getDate = function () {
|
|
var t = this.$dom.attr("data-target-date");
|
|
if (t) return new Date(t);
|
|
else return new Date();
|
|
}),
|
|
(CountdownCommon.prototype.getDirection = function () {
|
|
return this.$dom.attr("data-direction") || "down";
|
|
}),
|
|
(CountdownCommon.prototype.getTimeLeft = function () {
|
|
return this.$dom.attr("data-time-left") || "750m";
|
|
}),
|
|
(CountdownCommon.prototype.getNumber = function () {
|
|
var t = this.$dom.attr("data-target-number") || "100";
|
|
return parseInt(t, 10);
|
|
}),
|
|
(CountdownCommon.prototype.getStartTime = function () {
|
|
var t = this.$dom.attr("data-start-time");
|
|
if (t) return new Date(t);
|
|
else return new Date();
|
|
}),
|
|
(CountdownCommon.prototype.getFrequency = function () {
|
|
return this.$dom.attr("data-frequency") || "1s";
|
|
}),
|
|
(CountdownCommon.prototype.getTimerId = function () {
|
|
return this.$dom.attr("data-timer-id");
|
|
}),
|
|
(CountdownCommon.prototype.getTimerKey = function () {
|
|
return "timer-" + this.getTimerId();
|
|
}),
|
|
(CountdownCommon.prototype.getFor = function () {
|
|
return this.$dom.attr("data-for") || "everyone";
|
|
}),
|
|
(CountdownCommon.prototype.getType = function () {
|
|
return this.$dom.attr("data-type") || "to-date";
|
|
}),
|
|
(CountdownCommon.prototype.setValue = function (t, e, n, props) {
|
|
var i = this.$dom.find(".u-countdown-" + t),
|
|
o = e.toString(),
|
|
a = o.length;
|
|
if ("to-number" === this.getType()) {
|
|
for (; i.find(".u-countdown-number").length < a + 1;) {
|
|
var itemDom = i.find(".u-countdown-number:eq(0)");
|
|
if (!itemDom.length) break;
|
|
itemDom.clone().insertAfter(itemDom).text("0");
|
|
}
|
|
for (; i.find(".u-countdown-number").length > a + 1;)
|
|
i.find(".u-countdown-number:eq(0)").remove();
|
|
}
|
|
var s = i.find(".u-countdown-number");
|
|
if (
|
|
"hours" === t ||
|
|
"minutes" === t ||
|
|
"seconds" === t ||
|
|
"numbers" === t
|
|
)
|
|
for (; o.length < s.length;) o = "0" + o;
|
|
if (!(a > s.length))
|
|
for (var u = 0; u < s.length; u++) {
|
|
var l = $(s[u]);
|
|
if (
|
|
(this.doSetVal(l, o[u], props),
|
|
n && ("years" === t || "days" === t))
|
|
)
|
|
l.toggleClass("u-hidden", u >= a);
|
|
}
|
|
}),
|
|
(CountdownCommon.prototype.doSetVal = function (t, e, props) {
|
|
if ((props = props || {}).animation && "none" !== props.animation) {
|
|
var n = new CountdownAnimate(t);
|
|
if (n.getOldVal() !== e) n.rollNumber(e, props);
|
|
} else if (t.text() !== e) t.text(e);
|
|
}),
|
|
(CountdownCommon.prototype.showLabel = function (t, e) {
|
|
var n = this.$dom.find(".u-countdown-" + t);
|
|
n.toggleClass("u-hidden", !e),
|
|
n
|
|
.parent()
|
|
.children(".u-countdown-separator")
|
|
.each(function (t, el) {
|
|
var e = $(el),
|
|
n = e.prev(".u-countdown-item"),
|
|
i = e.nextAll(".u-countdown-item:not(.u-hidden)");
|
|
e.toggleClass(
|
|
"u-hidden",
|
|
!(n.is(":not(.u-hidden)") && i.is(":not(.u-hidden)"))
|
|
);
|
|
});
|
|
}),
|
|
(CountdownCommon.prototype.setAfterCountFinished = function () {
|
|
this.$dom.attr("data-after-count-finished", true);
|
|
}),
|
|
(CountdownCommon.prototype.getAfterCountFinished = function () {
|
|
var t = this.$dom.attr("data-after-count-finished") || "false";
|
|
return (t && "true" === t) || false;
|
|
}),
|
|
(CountdownCommon.prototype.getAfterCount = function () {
|
|
return this.$dom.attr("data-after-count") || "none";
|
|
}),
|
|
(CountdownCommon.prototype.getRedirectUrl = function () {
|
|
return this.$dom.attr("data-redirect-url") || "https://";
|
|
}),
|
|
(CountdownCommon.prototype.getCountAnimation = function () {
|
|
return this.$dom.attr("data-count-animation") || "none";
|
|
}),
|
|
(CountdownCommon.prototype.timeDiff = function (t) {
|
|
var e = new Date(),
|
|
n;
|
|
if ("down" === this.getDirection())
|
|
return CountdownCommon.calcTimeDiff(t, e);
|
|
else return CountdownCommon.calcTimeDiff(e, t);
|
|
}),
|
|
(CountdownCommon.prototype.calcNumber = function (t, e, n) {
|
|
var i = CountdownCommon.timeStringToMilliseconds(n);
|
|
if (!i) return 0;
|
|
var o = new Date(),
|
|
a = "up" === this.getDirection() ? 1 : -1,
|
|
s = t + Math.floor((o - e) / i) * a;
|
|
if (s < 0) return 0;
|
|
else return s;
|
|
}),
|
|
(CountdownCommon.prototype.parseTime = function (t, e) {
|
|
var n = CountdownCommon.timeStringToMilliseconds(t),
|
|
i = "down" === this.getDirection() ? 1 : -1;
|
|
return new Date(e.getTime() + n * i);
|
|
}),
|
|
(CountdownCommon.calcTimeDiff = function (t, e) {
|
|
if (t <= e) return CountdownCommon.emptyDiff();
|
|
var n = Math.abs(t - e) / 1e3,
|
|
i = Math.floor(n / 31536e3);
|
|
n -= 31536e3 * i;
|
|
var o = Math.floor(n / 86400);
|
|
n -= 86400 * o;
|
|
var a = Math.floor(n / 3600) % 24;
|
|
n -= 3600 * a;
|
|
var s = Math.floor(n / 60) % 60,
|
|
u;
|
|
return (
|
|
(n -= 60 * s),
|
|
{ years: i, days: o, hours: a, minutes: s, seconds: Math.floor(n) }
|
|
);
|
|
}),
|
|
(CountdownCommon.emptyDiff = function () {
|
|
return { years: 0, days: 0, hours: 0, minutes: 0, seconds: 0 };
|
|
}),
|
|
(CountdownCommon.isEmptyDiff = function (diff) {
|
|
if ("number" == typeof diff) return 0 === diff;
|
|
else
|
|
return (
|
|
0 === diff.years &&
|
|
0 === diff.days &&
|
|
0 === diff.hours &&
|
|
0 === diff.minutes &&
|
|
0 === diff.seconds
|
|
);
|
|
}),
|
|
(CountdownCommon.timeStringToMilliseconds = function (t) {
|
|
var data = t.match(/(\d+)(ms|s|m|h|d|)/);
|
|
if (data && 3 === data.length) {
|
|
var e = parseInt(data[1], 10);
|
|
switch (data[2]) {
|
|
case "ms":
|
|
return e;
|
|
case "s":
|
|
return 1e3 * e;
|
|
case "m":
|
|
return 60 * e * 1e3;
|
|
case "h":
|
|
return 3600 * e * 1e3;
|
|
case "d":
|
|
return 86400 * e * 1e3;
|
|
default:
|
|
return 0;
|
|
}
|
|
}
|
|
return 0;
|
|
});
|
|
},
|
|
363: function (t, e) {
|
|
var e = void 0,
|
|
t = void 0;
|
|
(function () {
|
|
/*!
|
|
* https://github.com/gilmoreorless/css-background-parser
|
|
* Copyright © 2015 Gilmore Davidson under the MIT license: http://gilmoreorless.mit-license.org/
|
|
*/
|
|
!(function (t) {
|
|
function e(t) {
|
|
if (!(this instanceof e)) return new e();
|
|
this.backgrounds = t || [];
|
|
}
|
|
function Background(props) {
|
|
function t(t, n) {
|
|
e[t] = t in props ? props[t] : n;
|
|
}
|
|
if (!(this instanceof Background)) return new Background(props);
|
|
props = props || {};
|
|
var e = this;
|
|
t("color", ""),
|
|
t("image", ""),
|
|
t("attachment", ""),
|
|
t("clip", ""),
|
|
t("origin", ""),
|
|
t("position", ""),
|
|
t("repeat", ""),
|
|
t("size", "");
|
|
}
|
|
function n(t) {
|
|
var e = [],
|
|
n = /[,\(\)]/,
|
|
i = 0,
|
|
o = "";
|
|
if (null == t) return e;
|
|
for (; t.length;) {
|
|
var a = n.exec(t);
|
|
if (!a) break;
|
|
var s,
|
|
u = false;
|
|
switch (a[0]) {
|
|
case ",":
|
|
if (!i) e.push(o.trim()), (o = ""), (u = true);
|
|
break;
|
|
case "(":
|
|
i++;
|
|
break;
|
|
case ")":
|
|
i--;
|
|
break;
|
|
}
|
|
var index = a.index + 1;
|
|
(o += t.slice(0, u ? index - 1 : index)), (t = t.slice(index));
|
|
}
|
|
if (o.length || t.length) e.push((o + t).trim());
|
|
return e.filter(function (t) {
|
|
return "none" !== t;
|
|
});
|
|
}
|
|
function i(t) {
|
|
return t.trim();
|
|
}
|
|
function o(t) {
|
|
return (t || "").split(",").map(i);
|
|
}
|
|
(e.prototype.toString = function t(props) {
|
|
return this.backgrounds
|
|
.map(function (t) {
|
|
return t.toString(props);
|
|
})
|
|
.filter(function (t) {
|
|
return t;
|
|
})
|
|
.join(", ");
|
|
}),
|
|
(Background.prototype.toString = function t(props) {
|
|
props = props || [
|
|
"image",
|
|
"repeat",
|
|
"attachment",
|
|
"position",
|
|
"size",
|
|
"origin",
|
|
"clip",
|
|
];
|
|
var size =
|
|
(props = Array.isArray(props) ? props : [props]).includes(
|
|
"size"
|
|
) && this.size
|
|
? " / " + this.size
|
|
: "",
|
|
list = [
|
|
props.includes("image") ? this.image : "",
|
|
props.includes("repeat") ? this.repeat : "",
|
|
props.includes("attachment") ? this.attachment : "",
|
|
props.includes("position") ? this.position + size : "",
|
|
props.includes("origin") ? this.origin : "",
|
|
props.includes("clip") ? this.clip : "",
|
|
];
|
|
if (this.color) list.unshift(this.color);
|
|
return list
|
|
.filter(function (t) {
|
|
return t;
|
|
})
|
|
.join(" ");
|
|
}),
|
|
(t.BackgroundList = e),
|
|
(t.Background = Background),
|
|
(t.parseElementStyle = function (t) {
|
|
var list = new e();
|
|
if (null == t) return list;
|
|
for (
|
|
var i = n(t.backgroundImage),
|
|
a = t.backgroundColor,
|
|
s = o(t.backgroundAttachment),
|
|
u = o(t.backgroundClip),
|
|
l = o(t.backgroundOrigin),
|
|
f = o(t.backgroundPosition),
|
|
c = o(t.backgroundRepeat),
|
|
h = o(t.backgroundSize),
|
|
background,
|
|
p = 0,
|
|
m = i.length;
|
|
p < m;
|
|
p++
|
|
) {
|
|
if (
|
|
((background = new Background({
|
|
image: i[p],
|
|
attachment: s[p % s.length],
|
|
clip: u[p % u.length],
|
|
origin: l[p % l.length],
|
|
position: f[p % f.length],
|
|
repeat: c[p % c.length],
|
|
size: h[p % h.length],
|
|
})),
|
|
p === m - 1)
|
|
)
|
|
background.color = a;
|
|
list.backgrounds.push(background);
|
|
}
|
|
return list;
|
|
});
|
|
})(
|
|
(function (e) {
|
|
if (void 0 !== t && void 0 !== t.exports) return t.exports;
|
|
else return (e.cssBgParser = {});
|
|
})(this)
|
|
);
|
|
}).call(window);
|
|
},
|
|
375: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
var e = t.length;
|
|
if (e % 4 > 0)
|
|
throw new Error("Invalid string. Length must be a multiple of 4");
|
|
var n = t.indexOf("="),
|
|
i;
|
|
if (-1 === n) n = e;
|
|
return [n, n === e ? 0 : 4 - (n % 4)];
|
|
}
|
|
function o(t) {
|
|
var e = i(t),
|
|
n = e[0],
|
|
o = e[1];
|
|
return (3 * (n + o)) / 4 - o;
|
|
}
|
|
function a(t, e, n) {
|
|
return (3 * (e + n)) / 4 - n;
|
|
}
|
|
function s(t) {
|
|
var e,
|
|
n = i(t),
|
|
o = n[0],
|
|
s = n[1],
|
|
u = new p(a(t, o, s)),
|
|
l = 0,
|
|
f = s > 0 ? o - 4 : o,
|
|
c;
|
|
for (c = 0; c < f; c += 4)
|
|
(e =
|
|
(h[t.charCodeAt(c)] << 18) |
|
|
(h[t.charCodeAt(c + 1)] << 12) |
|
|
(h[t.charCodeAt(c + 2)] << 6) |
|
|
h[t.charCodeAt(c + 3)]),
|
|
(u[l++] = (e >> 16) & 255),
|
|
(u[l++] = (e >> 8) & 255),
|
|
(u[l++] = 255 & e);
|
|
if (2 === s)
|
|
(e = (h[t.charCodeAt(c)] << 2) | (h[t.charCodeAt(c + 1)] >> 4)),
|
|
(u[l++] = 255 & e);
|
|
if (1 === s)
|
|
(e =
|
|
(h[t.charCodeAt(c)] << 10) |
|
|
(h[t.charCodeAt(c + 1)] << 4) |
|
|
(h[t.charCodeAt(c + 2)] >> 2)),
|
|
(u[l++] = (e >> 8) & 255),
|
|
(u[l++] = 255 & e);
|
|
return u;
|
|
}
|
|
function u(t) {
|
|
return (
|
|
c[(t >> 18) & 63] + c[(t >> 12) & 63] + c[(t >> 6) & 63] + c[63 & t]
|
|
);
|
|
}
|
|
function l(t, e, n) {
|
|
for (var i, o = [], a = e; a < n; a += 3)
|
|
(i =
|
|
((t[a] << 16) & 16711680) +
|
|
((t[a + 1] << 8) & 65280) +
|
|
(255 & t[a + 2])),
|
|
o.push(u(i));
|
|
return o.join("");
|
|
}
|
|
function f(t) {
|
|
for (
|
|
var e, n = t.length, i = n % 3, o = [], a = 16383, s = 0, u = n - i;
|
|
s < u;
|
|
s += a
|
|
)
|
|
o.push(l(t, s, s + a > u ? u : s + a));
|
|
if (1 === i) (e = t[n - 1]), o.push(c[e >> 2] + c[(e << 4) & 63] + "==");
|
|
else if (2 === i)
|
|
(e = (t[n - 2] << 8) + t[n - 1]),
|
|
o.push(c[e >> 10] + c[(e >> 4) & 63] + c[(e << 2) & 63] + "=");
|
|
return o.join("");
|
|
}
|
|
(e.byteLength = o), (e.toByteArray = s), (e.fromByteArray = f);
|
|
for (
|
|
var c = [],
|
|
h = [],
|
|
p = "undefined" != typeof Uint8Array ? Uint8Array : Array,
|
|
m = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",
|
|
v = 0,
|
|
g = m.length;
|
|
v < g;
|
|
++v
|
|
)
|
|
(c[v] = m[v]), (h[m.charCodeAt(v)] = v);
|
|
(h["-".charCodeAt(0)] = 62), (h["_".charCodeAt(0)] = 63);
|
|
},
|
|
376: function (t, e, n) {
|
|
"use strict";
|
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */ (e.read =
|
|
function (t, e, n, i, o) {
|
|
var a,
|
|
s,
|
|
u = 8 * o - i - 1,
|
|
l = (1 << u) - 1,
|
|
f = l >> 1,
|
|
c = -7,
|
|
h = n ? o - 1 : 0,
|
|
d = n ? -1 : 1,
|
|
p = t[e + h];
|
|
for (
|
|
h += d, a = p & ((1 << -c) - 1), p >>= -c, c += u;
|
|
c > 0;
|
|
a = 256 * a + t[e + h], h += d, c -= 8
|
|
);
|
|
for (
|
|
s = a & ((1 << -c) - 1), a >>= -c, c += i;
|
|
c > 0;
|
|
s = 256 * s + t[e + h], h += d, c -= 8
|
|
);
|
|
if (0 === a) a = 1 - f;
|
|
else if (a === l) return s ? NaN : (p ? -1 : 1) * (1 / 0);
|
|
else (s += Math.pow(2, i)), (a -= f);
|
|
return (p ? -1 : 1) * s * Math.pow(2, a - i);
|
|
}),
|
|
(e.write = function (t, e, n, i, o, a) {
|
|
var s,
|
|
u,
|
|
l,
|
|
f = 8 * a - o - 1,
|
|
c = (1 << f) - 1,
|
|
h = c >> 1,
|
|
p = 23 === o ? Math.pow(2, -24) - Math.pow(2, -77) : 0,
|
|
m = i ? 0 : a - 1,
|
|
d = i ? 1 : -1,
|
|
v = e < 0 || (0 === e && 1 / e < 0) ? 1 : 0;
|
|
if (((e = Math.abs(e)), isNaN(e) || e === 1 / 0))
|
|
(u = isNaN(e) ? 1 : 0), (s = c);
|
|
else {
|
|
if (
|
|
((s = Math.floor(Math.log(e) / Math.LN2)),
|
|
e * (l = Math.pow(2, -s)) < 1)
|
|
)
|
|
s--, (l *= 2);
|
|
if (s + h >= 1) e += p / l;
|
|
else e += p * Math.pow(2, 1 - h);
|
|
if (e * l >= 2) s++, (l /= 2);
|
|
if (s + h >= c) (u = 0), (s = c);
|
|
else if (s + h >= 1) (u = (e * l - 1) * Math.pow(2, o)), (s += h);
|
|
else (u = e * Math.pow(2, h - 1) * Math.pow(2, o)), (s = 0);
|
|
}
|
|
for (; o >= 8; t[n + m] = 255 & u, m += d, u /= 256, o -= 8);
|
|
for (
|
|
s = (s << o) | u, f += o;
|
|
f > 0;
|
|
t[n + m] = 255 & s, m += d, s /= 256, f -= 8
|
|
);
|
|
t[n + m - d] |= 128 * v;
|
|
});
|
|
},
|
|
377: function (t, e, n) {
|
|
"use strict";
|
|
var i = {}.toString;
|
|
t.exports =
|
|
Array.isArray ||
|
|
function (t) {
|
|
return "[object Array]" == i.call(t);
|
|
};
|
|
},
|
|
381: function (t, e, n) {
|
|
"use strict";
|
|
(function (t, e) {
|
|
!(function (t, n) {
|
|
function i(t) {
|
|
if ("function" != typeof t) t = new Function("" + t);
|
|
for (
|
|
var e = new Array(arguments.length - 1), n = 0;
|
|
n < e.length;
|
|
n++
|
|
)
|
|
e[n] = arguments[n + 1];
|
|
var i = { callback: t, args: e };
|
|
return (v[m] = i), w(m), m++;
|
|
}
|
|
function o(t) {
|
|
delete v[t];
|
|
}
|
|
function a(t) {
|
|
var e = t.callback,
|
|
i = t.args;
|
|
switch (i.length) {
|
|
case 0:
|
|
e();
|
|
break;
|
|
case 1:
|
|
e(i[0]);
|
|
break;
|
|
case 2:
|
|
e(i[0], i[1]);
|
|
break;
|
|
case 3:
|
|
e(i[0], i[1], i[2]);
|
|
break;
|
|
default:
|
|
e.apply(n, i);
|
|
break;
|
|
}
|
|
}
|
|
function s(t) {
|
|
if (g) setTimeout(s, 0, t);
|
|
else {
|
|
var e = v[t];
|
|
if (e) {
|
|
g = true;
|
|
try {
|
|
a(e);
|
|
} finally {
|
|
o(t), (g = false);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
function u() {
|
|
w = function (t) {
|
|
e.nextTick(function () {
|
|
s(t);
|
|
});
|
|
};
|
|
}
|
|
function l() {
|
|
if (t.postMessage && !t.importScripts) {
|
|
var e = true,
|
|
n = t.onmessage;
|
|
return (
|
|
(t.onmessage = function () {
|
|
e = false;
|
|
}),
|
|
t.postMessage("", "*"),
|
|
(t.onmessage = n),
|
|
e
|
|
);
|
|
}
|
|
}
|
|
function f() {
|
|
var e = "setImmediate$" + Math.random() + "$",
|
|
n = function (n) {
|
|
if (
|
|
n.source === t &&
|
|
"string" == typeof n.data &&
|
|
0 === n.data.indexOf(e)
|
|
)
|
|
s(+n.data.slice(e.length));
|
|
};
|
|
if (t.addEventListener) t.addEventListener("message", n, false);
|
|
else t.attachEvent("onmessage", n);
|
|
w = function (n) {
|
|
t.postMessage(e + n, "*");
|
|
};
|
|
}
|
|
function c() {
|
|
var t = new MessageChannel();
|
|
(t.port1.onmessage = function (t) {
|
|
var e;
|
|
s(t.data);
|
|
}),
|
|
(w = function (e) {
|
|
t.port2.postMessage(e);
|
|
});
|
|
}
|
|
function h() {
|
|
var t = y.documentElement;
|
|
w = function (e) {
|
|
var n = y.createElement("script");
|
|
(n.onreadystatechange = function () {
|
|
s(e), (n.onreadystatechange = null), t.removeChild(n), (n = null);
|
|
}),
|
|
t.appendChild(n);
|
|
};
|
|
}
|
|
function p() {
|
|
w = function (t) {
|
|
setTimeout(s, 0, t);
|
|
};
|
|
}
|
|
if (!t.setImmediate) {
|
|
var m = 1,
|
|
v = {},
|
|
g = false,
|
|
y = t.document,
|
|
w,
|
|
b = Object.getPrototypeOf && Object.getPrototypeOf(t);
|
|
if (
|
|
((b = b && b.setTimeout ? b : t),
|
|
"[object process]" === {}.toString.call(t.process))
|
|
)
|
|
u();
|
|
else if (l()) f();
|
|
else if (t.MessageChannel) c();
|
|
else if (y && "onreadystatechange" in y.createElement("script")) h();
|
|
else p();
|
|
(b.setImmediate = i), (b.clearImmediate = o);
|
|
}
|
|
})("undefined" == typeof self ? (void 0 === t ? this : t) : self);
|
|
}).call(e, n(41), n(86));
|
|
},
|
|
382: function (t, e, n) {
|
|
"use strict";
|
|
(function (e) {
|
|
function n(input, t) {
|
|
var e = 0,
|
|
base = t.length,
|
|
n = t.charAt(0),
|
|
i = [0];
|
|
for (e = 0; e < input.length(); ++e) {
|
|
for (var o = 0, a = input.at(e); o < i.length; ++o)
|
|
(a += i[o] << 8), (i[o] = a % base), (a = (a / base) | 0);
|
|
for (; a > 0;) i.push(a % base), (a = (a / base) | 0);
|
|
}
|
|
var s = "";
|
|
for (e = 0; 0 === input.at(e) && e < input.length() - 1; ++e) s += n;
|
|
for (e = i.length - 1; e >= 0; --e) s += t[i[e]];
|
|
return s;
|
|
}
|
|
var i = {};
|
|
t.exports = i;
|
|
var o = {};
|
|
(i.encode = function (input, t, e) {
|
|
if ("string" != typeof t)
|
|
throw new TypeError('"alphabet" must be a string.');
|
|
if (void 0 !== e && "number" != typeof e)
|
|
throw new TypeError('"maxline" must be a number.');
|
|
var i = "";
|
|
if (!(input instanceof Uint8Array)) i = n(input, t);
|
|
else {
|
|
var o = 0,
|
|
base = t.length,
|
|
a = t.charAt(0),
|
|
s = [0];
|
|
for (o = 0; o < input.length; ++o) {
|
|
for (var u = 0, l = input[o]; u < s.length; ++u)
|
|
(l += s[u] << 8), (s[u] = l % base), (l = (l / base) | 0);
|
|
for (; l > 0;) s.push(l % base), (l = (l / base) | 0);
|
|
}
|
|
for (o = 0; 0 === input[o] && o < input.length - 1; ++o) i += a;
|
|
for (o = s.length - 1; o >= 0; --o) i += t[s[o]];
|
|
}
|
|
if (e) {
|
|
var f = new RegExp(".{1," + e + "}", "g");
|
|
i = i.match(f).join("\r\n");
|
|
}
|
|
return i;
|
|
}),
|
|
(i.decode = function (input, t) {
|
|
if ("string" != typeof input)
|
|
throw new TypeError('"input" must be a string.');
|
|
if ("string" != typeof t)
|
|
throw new TypeError('"alphabet" must be a string.');
|
|
var table = o[t];
|
|
if (!table) {
|
|
table = o[t] = [];
|
|
for (var n = 0; n < t.length; ++n) table[t.charCodeAt(n)] = n;
|
|
}
|
|
input = input.replace(/\s/g, "");
|
|
for (
|
|
var base = t.length, i = t.charAt(0), a = [0], n = 0;
|
|
n < input.length;
|
|
n++
|
|
) {
|
|
var s = table[input.charCodeAt(n)];
|
|
if (void 0 === s) return;
|
|
for (var u = 0, l = s; u < a.length; ++u)
|
|
(l += a[u] * base), (a[u] = 255 & l), (l >>= 8);
|
|
for (; l > 0;) a.push(255 & l), (l >>= 8);
|
|
}
|
|
for (var f = 0; input[f] === i && f < input.length - 1; ++f)
|
|
a.push(0);
|
|
if (void 0 !== e) return e.from(a.reverse());
|
|
else return new Uint8Array(a.reverse());
|
|
});
|
|
}).call(e, n(42).Buffer);
|
|
},
|
|
41: function (t, e, n) {
|
|
"use strict";
|
|
var i;
|
|
i = (function () {
|
|
return this;
|
|
})();
|
|
try {
|
|
i = i || Function("return this")() || (1, eval)("this");
|
|
} catch (t) {
|
|
if ("object" == typeof window) i = window;
|
|
}
|
|
t.exports = i;
|
|
},
|
|
42: function (t, e, n) {
|
|
"use strict";
|
|
(function (t) {
|
|
function i() {
|
|
try {
|
|
var t = new Uint8Array(1);
|
|
return (
|
|
(t.__proto__ = {
|
|
__proto__: Uint8Array.prototype,
|
|
foo: function () {
|
|
return 42;
|
|
},
|
|
}),
|
|
42 === t.foo() &&
|
|
"function" == typeof t.subarray &&
|
|
0 === t.subarray(1, 1).byteLength
|
|
);
|
|
} catch (t) {
|
|
return false;
|
|
}
|
|
}
|
|
function o() {
|
|
return s.TYPED_ARRAY_SUPPORT ? 2147483647 : 1073741823;
|
|
}
|
|
function a(t, length) {
|
|
if (o() < length) throw new RangeError("Invalid typed array length");
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(t = new Uint8Array(length)).__proto__ = s.prototype;
|
|
else {
|
|
if (null === t) t = new s(length);
|
|
t.length = length;
|
|
}
|
|
return t;
|
|
}
|
|
function s(t, e, length) {
|
|
if (!(s.TYPED_ARRAY_SUPPORT || this instanceof s))
|
|
return new s(t, e, length);
|
|
if ("number" == typeof t) {
|
|
if ("string" == typeof e)
|
|
throw new Error(
|
|
"If encoding is specified then the first argument must be a string"
|
|
);
|
|
return c(this, t);
|
|
}
|
|
return u(this, t, e, length);
|
|
}
|
|
function u(t, e, n, length) {
|
|
if ("number" == typeof e)
|
|
throw new TypeError('"value" argument must not be a number');
|
|
if ("undefined" != typeof ArrayBuffer && e instanceof ArrayBuffer)
|
|
return m(t, e, n, length);
|
|
if ("string" == typeof e) return h(t, e, n);
|
|
else return v(t, e);
|
|
}
|
|
function l(size) {
|
|
if ("number" != typeof size)
|
|
throw new TypeError('"size" argument must be a number');
|
|
else if (size < 0)
|
|
throw new RangeError('"size" argument must not be negative');
|
|
}
|
|
function f(t, size, e, n) {
|
|
if ((l(size), size <= 0)) return a(t, size);
|
|
if (void 0 !== e)
|
|
return "string" == typeof n
|
|
? a(t, size).fill(e, n)
|
|
: a(t, size).fill(e);
|
|
else return a(t, size);
|
|
}
|
|
function c(t, size) {
|
|
if (
|
|
(l(size),
|
|
(t = a(t, size < 0 ? 0 : 0 | g(size))),
|
|
!s.TYPED_ARRAY_SUPPORT)
|
|
)
|
|
for (var e = 0; e < size; ++e) t[e] = 0;
|
|
return t;
|
|
}
|
|
function h(t, e, n) {
|
|
if ("string" != typeof n || "" === n) n = "utf8";
|
|
if (!s.isEncoding(n))
|
|
throw new TypeError('"encoding" must be a valid string encoding');
|
|
var length = 0 | w(e, n),
|
|
i = (t = a(t, length)).write(e, n);
|
|
if (i !== length) t = t.slice(0, i);
|
|
return t;
|
|
}
|
|
function p(t, e) {
|
|
var length = e.length < 0 ? 0 : 0 | g(e.length);
|
|
t = a(t, length);
|
|
for (var n = 0; n < length; n += 1) t[n] = 255 & e[n];
|
|
return t;
|
|
}
|
|
function m(t, e, n, length) {
|
|
if ((e.byteLength, n < 0 || e.byteLength < n))
|
|
throw new RangeError("'offset' is out of bounds");
|
|
if (e.byteLength < n + (length || 0))
|
|
throw new RangeError("'length' is out of bounds");
|
|
if (void 0 === n && void 0 === length) e = new Uint8Array(e);
|
|
else if (void 0 === length) e = new Uint8Array(e, n);
|
|
else e = new Uint8Array(e, n, length);
|
|
if (s.TYPED_ARRAY_SUPPORT) (t = e).__proto__ = s.prototype;
|
|
else t = p(t, e);
|
|
return t;
|
|
}
|
|
function v(t, e) {
|
|
if (s.isBuffer(e)) {
|
|
var n = 0 | g(e.length);
|
|
if (0 === (t = a(t, n)).length) return t;
|
|
else return e.copy(t, 0, 0, n), t;
|
|
}
|
|
if (e) {
|
|
if (
|
|
("undefined" != typeof ArrayBuffer &&
|
|
e.buffer instanceof ArrayBuffer) ||
|
|
"length" in e
|
|
)
|
|
if ("number" != typeof e.length || rt(e.length)) return a(t, 0);
|
|
else return p(t, e);
|
|
if ("Buffer" === e.type && st(e.data)) return p(t, e.data);
|
|
}
|
|
throw new TypeError(
|
|
"First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object."
|
|
);
|
|
}
|
|
function g(length) {
|
|
if (length >= o())
|
|
throw new RangeError(
|
|
"Attempt to allocate Buffer larger than maximum " +
|
|
"size: 0x" +
|
|
o().toString(16) +
|
|
" bytes"
|
|
);
|
|
return 0 | length;
|
|
}
|
|
function y(length) {
|
|
if (+length != length) length = 0;
|
|
return s.alloc(+length);
|
|
}
|
|
function w(t, e) {
|
|
if (s.isBuffer(t)) return t.length;
|
|
if (
|
|
"undefined" != typeof ArrayBuffer &&
|
|
"function" == typeof ArrayBuffer.isView &&
|
|
(ArrayBuffer.isView(t) || t instanceof ArrayBuffer)
|
|
)
|
|
return t.byteLength;
|
|
if ("string" != typeof t) t = "" + t;
|
|
var n = t.length;
|
|
if (0 === n) return 0;
|
|
for (var i = false; ;)
|
|
switch (e) {
|
|
case "ascii":
|
|
case "latin1":
|
|
case "binary":
|
|
return n;
|
|
case "utf8":
|
|
case "utf-8":
|
|
case void 0:
|
|
return X(t).length;
|
|
case "ucs2":
|
|
case "ucs-2":
|
|
case "utf16le":
|
|
case "utf-16le":
|
|
return 2 * n;
|
|
case "hex":
|
|
return n >>> 1;
|
|
case "base64":
|
|
return tt(t).length;
|
|
default:
|
|
if (i) return X(t).length;
|
|
(e = ("" + e).toLowerCase()), (i = true);
|
|
}
|
|
}
|
|
function b(t, e, n) {
|
|
var i = false;
|
|
if (void 0 === e || e < 0) e = 0;
|
|
if (e > this.length) return "";
|
|
if (void 0 === n || n > this.length) n = this.length;
|
|
if (n <= 0) return "";
|
|
if ((n >>>= 0) <= (e >>>= 0)) return "";
|
|
if (!t) t = "utf8";
|
|
for (; true;)
|
|
switch (t) {
|
|
case "hex":
|
|
return F(this, e, n);
|
|
case "utf8":
|
|
case "utf-8":
|
|
return L(this, e, n);
|
|
case "ascii":
|
|
return O(this, e, n);
|
|
case "latin1":
|
|
case "binary":
|
|
return P(this, e, n);
|
|
case "base64":
|
|
return M(this, e, n);
|
|
case "ucs2":
|
|
case "ucs-2":
|
|
case "utf16le":
|
|
case "utf-16le":
|
|
return N(this, e, n);
|
|
default:
|
|
if (i) throw new TypeError("Unknown encoding: " + t);
|
|
(t = (t + "").toLowerCase()), (i = true);
|
|
}
|
|
}
|
|
function C(t, e, n) {
|
|
var i = t[e];
|
|
(t[e] = t[n]), (t[n] = i);
|
|
}
|
|
function x(t, e, n, i, o) {
|
|
if (0 === t.length) return -1;
|
|
if ("string" == typeof n) (i = n), (n = 0);
|
|
else if (n > 2147483647) n = 2147483647;
|
|
else if (n < -2147483648) n = -2147483648;
|
|
if (((n = +n), isNaN(n))) n = o ? 0 : t.length - 1;
|
|
if (n < 0) n = t.length + n;
|
|
if (n >= t.length)
|
|
if (o) return -1;
|
|
else n = t.length - 1;
|
|
else if (n < 0)
|
|
if (o) n = 0;
|
|
else return -1;
|
|
if ("string" == typeof e) e = s.from(e, i);
|
|
if (s.isBuffer(e))
|
|
if (0 === e.length) return -1;
|
|
else return S(t, e, n, i, o);
|
|
else if ("number" == typeof e) {
|
|
if (
|
|
((e &= 255),
|
|
s.TYPED_ARRAY_SUPPORT &&
|
|
"function" == typeof Uint8Array.prototype.indexOf)
|
|
)
|
|
if (o) return Uint8Array.prototype.indexOf.call(t, e, n);
|
|
else return Uint8Array.prototype.lastIndexOf.call(t, e, n);
|
|
return S(t, [e], n, i, o);
|
|
}
|
|
throw new TypeError("val must be string, number or Buffer");
|
|
}
|
|
function S(t, e, n, i, o) {
|
|
function a(t, e) {
|
|
if (1 === s) return t[e];
|
|
else return t.readUInt16BE(e * s);
|
|
}
|
|
var s = 1,
|
|
u = t.length,
|
|
l = e.length,
|
|
f;
|
|
if (void 0 !== i)
|
|
if (
|
|
"ucs2" === (i = String(i).toLowerCase()) ||
|
|
"ucs-2" === i ||
|
|
"utf16le" === i ||
|
|
"utf-16le" === i
|
|
) {
|
|
if (t.length < 2 || e.length < 2) return -1;
|
|
(s = 2), (u /= 2), (l /= 2), (n /= 2);
|
|
}
|
|
if (o) {
|
|
var c = -1;
|
|
for (f = n; f < u; f++)
|
|
if (a(t, f) === a(e, -1 === c ? 0 : f - c)) {
|
|
if (-1 === c) c = f;
|
|
if (f - c + 1 === l) return c * s;
|
|
} else {
|
|
if (-1 !== c) f -= f - c;
|
|
c = -1;
|
|
}
|
|
} else {
|
|
if (n + l > u) n = u - l;
|
|
for (f = n; f >= 0; f--) {
|
|
for (var h = true, p = 0; p < l; p++)
|
|
if (a(t, f + p) !== a(e, p)) {
|
|
h = false;
|
|
break;
|
|
}
|
|
if (h) return f;
|
|
}
|
|
}
|
|
return -1;
|
|
}
|
|
function A(t, e, n, length) {
|
|
n = Number(n) || 0;
|
|
var i = t.length - n;
|
|
if (!length) length = i;
|
|
else if ((length = Number(length)) > i) length = i;
|
|
var o = e.length;
|
|
if (o % 2 != 0) throw new TypeError("Invalid hex string");
|
|
if (length > o / 2) length = o / 2;
|
|
for (var a = 0; a < length; ++a) {
|
|
var s = parseInt(e.substr(2 * a, 2), 16);
|
|
if (isNaN(s)) return a;
|
|
t[n + a] = s;
|
|
}
|
|
return a;
|
|
}
|
|
function _(t, e, n, length) {
|
|
return nt(X(e, t.length - n), t, n, length);
|
|
}
|
|
function T(t, e, n, length) {
|
|
return nt(K(e), t, n, length);
|
|
}
|
|
function I(t, e, n, length) {
|
|
return T(t, e, n, length);
|
|
}
|
|
function E(t, e, n, length) {
|
|
return nt(tt(e), t, n, length);
|
|
}
|
|
function k(t, e, n, length) {
|
|
return nt(J(e, t.length - n), t, n, length);
|
|
}
|
|
function M(t, e, n) {
|
|
if (0 === e && n === t.length) return ot.fromByteArray(t);
|
|
else return ot.fromByteArray(t.slice(e, n));
|
|
}
|
|
function L(t, e, n) {
|
|
n = Math.min(t.length, n);
|
|
for (var i = [], o = e; o < n;) {
|
|
var a = t[o],
|
|
s = null,
|
|
u = a > 239 ? 4 : a > 223 ? 3 : a > 191 ? 2 : 1;
|
|
if (o + u <= n) {
|
|
var l, f, c, h;
|
|
switch (u) {
|
|
case 1:
|
|
if (a < 128) s = a;
|
|
break;
|
|
case 2:
|
|
if (128 == (192 & (l = t[o + 1])))
|
|
if ((h = ((31 & a) << 6) | (63 & l)) > 127) s = h;
|
|
break;
|
|
case 3:
|
|
if (
|
|
((l = t[o + 1]),
|
|
(f = t[o + 2]),
|
|
128 == (192 & l) && 128 == (192 & f))
|
|
)
|
|
if (
|
|
(h = ((15 & a) << 12) | ((63 & l) << 6) | (63 & f)) >
|
|
2047 &&
|
|
(h < 55296 || h > 57343)
|
|
)
|
|
s = h;
|
|
break;
|
|
case 4:
|
|
if (
|
|
((l = t[o + 1]),
|
|
(f = t[o + 2]),
|
|
(c = t[o + 3]),
|
|
128 == (192 & l) && 128 == (192 & f) && 128 == (192 & c))
|
|
)
|
|
if (
|
|
(h =
|
|
((15 & a) << 18) |
|
|
((63 & l) << 12) |
|
|
((63 & f) << 6) |
|
|
(63 & c)) > 65535 &&
|
|
h < 1114112
|
|
)
|
|
s = h;
|
|
}
|
|
}
|
|
if (null === s) (s = 65533), (u = 1);
|
|
else if (s > 65535)
|
|
(s -= 65536),
|
|
i.push(((s >>> 10) & 1023) | 55296),
|
|
(s = 56320 | (1023 & s));
|
|
i.push(s), (o += u);
|
|
}
|
|
return B(i);
|
|
}
|
|
function B(t) {
|
|
var e = t.length;
|
|
if (e <= ut) return String.fromCharCode.apply(String, t);
|
|
for (var n = "", i = 0; i < e;)
|
|
n += String.fromCharCode.apply(String, t.slice(i, (i += ut)));
|
|
return n;
|
|
}
|
|
function O(t, e, n) {
|
|
var i = "";
|
|
n = Math.min(t.length, n);
|
|
for (var o = e; o < n; ++o) i += String.fromCharCode(127 & t[o]);
|
|
return i;
|
|
}
|
|
function P(t, e, n) {
|
|
var i = "";
|
|
n = Math.min(t.length, n);
|
|
for (var o = e; o < n; ++o) i += String.fromCharCode(t[o]);
|
|
return i;
|
|
}
|
|
function F(t, e, n) {
|
|
var i = t.length;
|
|
if (!e || e < 0) e = 0;
|
|
if (!n || n < 0 || n > i) n = i;
|
|
for (var o = "", a = e; a < n; ++a) o += Z(t[a]);
|
|
return o;
|
|
}
|
|
function N(t, e, n) {
|
|
for (var i = t.slice(e, n), o = "", a = 0; a < i.length; a += 2)
|
|
o += String.fromCharCode(i[a] + 256 * i[a + 1]);
|
|
return o;
|
|
}
|
|
function z(t, e, length) {
|
|
if (t % 1 != 0 || t < 0) throw new RangeError("offset is not uint");
|
|
if (t + e > length)
|
|
throw new RangeError("Trying to access beyond buffer length");
|
|
}
|
|
function U(t, e, n, i, o, a) {
|
|
if (!s.isBuffer(t))
|
|
throw new TypeError('"buffer" argument must be a Buffer instance');
|
|
if (e > o || e < a)
|
|
throw new RangeError('"value" argument is out of bounds');
|
|
if (n + i > t.length) throw new RangeError("Index out of range");
|
|
}
|
|
function H(t, e, n, i) {
|
|
if (e < 0) e = 65535 + e + 1;
|
|
for (var o = 0, a = Math.min(t.length - n, 2); o < a; ++o)
|
|
t[n + o] =
|
|
(e & (255 << (8 * (i ? o : 1 - o)))) >>> (8 * (i ? o : 1 - o));
|
|
}
|
|
function $(t, e, n, i) {
|
|
if (e < 0) e = 4294967295 + e + 1;
|
|
for (var o = 0, a = Math.min(t.length - n, 4); o < a; ++o)
|
|
t[n + o] = (e >>> (8 * (i ? o : 3 - o))) & 255;
|
|
}
|
|
function V(t, e, n, i, o, a) {
|
|
if (n + i > t.length) throw new RangeError("Index out of range");
|
|
if (n < 0) throw new RangeError("Index out of range");
|
|
}
|
|
function Y(t, e, n, i, o) {
|
|
if (!o) V(t, e, n, 4, 34028234663852886e22, -34028234663852886e22);
|
|
return at.write(t, e, n, i, 23, 4), n + 4;
|
|
}
|
|
function W(t, e, n, i, o) {
|
|
if (!o) V(t, e, n, 8, 17976931348623157e292, -17976931348623157e292);
|
|
return at.write(t, e, n, i, 52, 8), n + 8;
|
|
}
|
|
function j(t) {
|
|
if ((t = G(t).replace(lt, "")).length < 2) return "";
|
|
for (; t.length % 4 != 0;) t += "=";
|
|
return t;
|
|
}
|
|
function G(t) {
|
|
if (t.trim) return t.trim();
|
|
else return t.replace(/^\s+|\s+$/g, "");
|
|
}
|
|
function Z(t) {
|
|
if (t < 16) return "0" + t.toString(16);
|
|
else return t.toString(16);
|
|
}
|
|
function X(t, e) {
|
|
var n;
|
|
e = e || 1 / 0;
|
|
for (var length = t.length, i = null, o = [], a = 0; a < length; ++a) {
|
|
if ((n = t.charCodeAt(a)) > 55295 && n < 57344) {
|
|
if (!i) {
|
|
if (n > 56319) {
|
|
if ((e -= 3) > -1) o.push(239, 191, 189);
|
|
continue;
|
|
} else if (a + 1 === length) {
|
|
if ((e -= 3) > -1) o.push(239, 191, 189);
|
|
continue;
|
|
}
|
|
i = n;
|
|
continue;
|
|
}
|
|
if (n < 56320) {
|
|
if ((e -= 3) > -1) o.push(239, 191, 189);
|
|
i = n;
|
|
continue;
|
|
}
|
|
n = (((i - 55296) << 10) | (n - 56320)) + 65536;
|
|
} else if (i) if ((e -= 3) > -1) o.push(239, 191, 189);
|
|
if (((i = null), n < 128)) {
|
|
if ((e -= 1) < 0) break;
|
|
o.push(n);
|
|
} else if (n < 2048) {
|
|
if ((e -= 2) < 0) break;
|
|
o.push((n >> 6) | 192, (63 & n) | 128);
|
|
} else if (n < 65536) {
|
|
if ((e -= 3) < 0) break;
|
|
o.push((n >> 12) | 224, ((n >> 6) & 63) | 128, (63 & n) | 128);
|
|
} else if (n < 1114112) {
|
|
if ((e -= 4) < 0) break;
|
|
o.push(
|
|
(n >> 18) | 240,
|
|
((n >> 12) & 63) | 128,
|
|
((n >> 6) & 63) | 128,
|
|
(63 & n) | 128
|
|
);
|
|
} else throw new Error("Invalid code point");
|
|
}
|
|
return o;
|
|
}
|
|
function K(t) {
|
|
for (var e = [], n = 0; n < t.length; ++n)
|
|
e.push(255 & t.charCodeAt(n));
|
|
return e;
|
|
}
|
|
function J(t, e) {
|
|
for (var n, i, o, a = [], s = 0; s < t.length && !((e -= 2) < 0); ++s)
|
|
(i = (n = t.charCodeAt(s)) >> 8), (o = n % 256), a.push(o), a.push(i);
|
|
return a;
|
|
}
|
|
function tt(t) {
|
|
return ot.toByteArray(j(t));
|
|
}
|
|
function nt(t, e, n, length) {
|
|
for (
|
|
var i = 0;
|
|
i < length && !(i + n >= e.length || i >= t.length);
|
|
++i
|
|
)
|
|
e[i + n] = t[i];
|
|
return i;
|
|
}
|
|
function rt(t) {
|
|
return t != t;
|
|
}
|
|
var ot = n(375),
|
|
at = n(376),
|
|
st = n(377);
|
|
if (
|
|
((e.Buffer = s),
|
|
(e.SlowBuffer = y),
|
|
(e.INSPECT_MAX_BYTES = 50),
|
|
(s.TYPED_ARRAY_SUPPORT =
|
|
void 0 !== t.TYPED_ARRAY_SUPPORT ? t.TYPED_ARRAY_SUPPORT : i()),
|
|
(e.kMaxLength = o()),
|
|
(s.poolSize = 8192),
|
|
(s._augment = function (t) {
|
|
return (t.__proto__ = s.prototype), t;
|
|
}),
|
|
(s.from = function (t, e, length) {
|
|
return u(null, t, e, length);
|
|
}),
|
|
s.TYPED_ARRAY_SUPPORT)
|
|
)
|
|
if (
|
|
((s.prototype.__proto__ = Uint8Array.prototype),
|
|
(s.__proto__ = Uint8Array),
|
|
"undefined" != typeof Symbol &&
|
|
Symbol.species &&
|
|
s[Symbol.species] === s)
|
|
)
|
|
Object.defineProperty(s, Symbol.species, {
|
|
value: null,
|
|
configurable: true,
|
|
});
|
|
(s.alloc = function (size, t, e) {
|
|
return f(null, size, t, e);
|
|
}),
|
|
(s.allocUnsafe = function (size) {
|
|
return c(null, size);
|
|
}),
|
|
(s.allocUnsafeSlow = function (size) {
|
|
return c(null, size);
|
|
}),
|
|
(s.isBuffer = function t(e) {
|
|
return !!(null != e && e._isBuffer);
|
|
}),
|
|
(s.compare = function compare(t, e) {
|
|
if (!s.isBuffer(t) || !s.isBuffer(e))
|
|
throw new TypeError("Arguments must be Buffers");
|
|
if (t === e) return 0;
|
|
for (
|
|
var n = t.length, i = e.length, o = 0, a = Math.min(n, i);
|
|
o < a;
|
|
++o
|
|
)
|
|
if (t[o] !== e[o]) {
|
|
(n = t[o]), (i = e[o]);
|
|
break;
|
|
}
|
|
if (n < i) return -1;
|
|
if (i < n) return 1;
|
|
else return 0;
|
|
}),
|
|
(s.isEncoding = function t(e) {
|
|
switch (String(e).toLowerCase()) {
|
|
case "hex":
|
|
case "utf8":
|
|
case "utf-8":
|
|
case "ascii":
|
|
case "latin1":
|
|
case "binary":
|
|
case "base64":
|
|
case "ucs2":
|
|
case "ucs-2":
|
|
case "utf16le":
|
|
case "utf-16le":
|
|
return true;
|
|
default:
|
|
return false;
|
|
}
|
|
}),
|
|
(s.concat = function t(list, length) {
|
|
if (!st(list))
|
|
throw new TypeError('"list" argument must be an Array of Buffers');
|
|
if (0 === list.length) return s.alloc(0);
|
|
var e;
|
|
if (void 0 === length)
|
|
for (length = 0, e = 0; e < list.length; ++e)
|
|
length += list[e].length;
|
|
var n = s.allocUnsafe(length),
|
|
i = 0;
|
|
for (e = 0; e < list.length; ++e) {
|
|
var o = list[e];
|
|
if (!s.isBuffer(o))
|
|
throw new TypeError(
|
|
'"list" argument must be an Array of Buffers'
|
|
);
|
|
o.copy(n, i), (i += o.length);
|
|
}
|
|
return n;
|
|
}),
|
|
(s.byteLength = w),
|
|
(s.prototype._isBuffer = true),
|
|
(s.prototype.swap16 = function t() {
|
|
var e = this.length;
|
|
if (e % 2 != 0)
|
|
throw new RangeError("Buffer size must be a multiple of 16-bits");
|
|
for (var n = 0; n < e; n += 2) C(this, n, n + 1);
|
|
return this;
|
|
}),
|
|
(s.prototype.swap32 = function t() {
|
|
var e = this.length;
|
|
if (e % 4 != 0)
|
|
throw new RangeError("Buffer size must be a multiple of 32-bits");
|
|
for (var n = 0; n < e; n += 4)
|
|
C(this, n, n + 3), C(this, n + 1, n + 2);
|
|
return this;
|
|
}),
|
|
(s.prototype.swap64 = function t() {
|
|
var e = this.length;
|
|
if (e % 8 != 0)
|
|
throw new RangeError("Buffer size must be a multiple of 64-bits");
|
|
for (var n = 0; n < e; n += 8)
|
|
C(this, n, n + 7),
|
|
C(this, n + 1, n + 6),
|
|
C(this, n + 2, n + 5),
|
|
C(this, n + 3, n + 4);
|
|
return this;
|
|
}),
|
|
(s.prototype.toString = function t() {
|
|
var length = 0 | this.length;
|
|
if (0 === length) return "";
|
|
if (0 === arguments.length) return L(this, 0, length);
|
|
else return b.apply(this, arguments);
|
|
}),
|
|
(s.prototype.equals = function t(e) {
|
|
if (!s.isBuffer(e)) throw new TypeError("Argument must be a Buffer");
|
|
if (this === e) return true;
|
|
else return 0 === s.compare(this, e);
|
|
}),
|
|
(s.prototype.inspect = function t() {
|
|
var n = "",
|
|
i = e.INSPECT_MAX_BYTES;
|
|
if (this.length > 0)
|
|
if (
|
|
((n = this.toString("hex", 0, i).match(/.{2}/g).join(" ")),
|
|
this.length > i)
|
|
)
|
|
n += " ... ";
|
|
return "<Buffer " + n + ">";
|
|
}),
|
|
(s.prototype.compare = function compare(t, e, n, i, o) {
|
|
if (!s.isBuffer(t)) throw new TypeError("Argument must be a Buffer");
|
|
if (void 0 === e) e = 0;
|
|
if (void 0 === n) n = t ? t.length : 0;
|
|
if (void 0 === i) i = 0;
|
|
if (void 0 === o) o = this.length;
|
|
if (e < 0 || n > t.length || i < 0 || o > this.length)
|
|
throw new RangeError("out of range index");
|
|
if (i >= o && e >= n) return 0;
|
|
if (i >= o) return -1;
|
|
if (e >= n) return 1;
|
|
if (this === t) return 0;
|
|
for (
|
|
var a = (o >>>= 0) - (i >>>= 0),
|
|
u = (n >>>= 0) - (e >>>= 0),
|
|
l = Math.min(a, u),
|
|
f = this.slice(i, o),
|
|
c = t.slice(e, n),
|
|
h = 0;
|
|
h < l;
|
|
++h
|
|
)
|
|
if (f[h] !== c[h]) {
|
|
(a = f[h]), (u = c[h]);
|
|
break;
|
|
}
|
|
if (a < u) return -1;
|
|
if (u < a) return 1;
|
|
else return 0;
|
|
}),
|
|
(s.prototype.includes = function t(e, n, i) {
|
|
return -1 !== this.indexOf(e, n, i);
|
|
}),
|
|
(s.prototype.indexOf = function t(e, n, i) {
|
|
return x(this, e, n, i, true);
|
|
}),
|
|
(s.prototype.lastIndexOf = function t(e, n, i) {
|
|
return x(this, e, n, i, false);
|
|
}),
|
|
(s.prototype.write = function t(e, n, length, i) {
|
|
if (void 0 === n) (i = "utf8"), (length = this.length), (n = 0);
|
|
else if (void 0 === length && "string" == typeof n)
|
|
(i = n), (length = this.length), (n = 0);
|
|
else if (isFinite(n))
|
|
if (((n |= 0), isFinite(length))) {
|
|
if (((length |= 0), void 0 === i)) i = "utf8";
|
|
} else (i = length), (length = void 0);
|
|
else
|
|
throw new Error(
|
|
"Buffer.write(string, encoding, offset[, length]) is no longer supported"
|
|
);
|
|
var o = this.length - n;
|
|
if (void 0 === length || length > o) length = o;
|
|
if ((e.length > 0 && (length < 0 || n < 0)) || n > this.length)
|
|
throw new RangeError("Attempt to write outside buffer bounds");
|
|
if (!i) i = "utf8";
|
|
for (var a = false; ;)
|
|
switch (i) {
|
|
case "hex":
|
|
return A(this, e, n, length);
|
|
case "utf8":
|
|
case "utf-8":
|
|
return _(this, e, n, length);
|
|
case "ascii":
|
|
return T(this, e, n, length);
|
|
case "latin1":
|
|
case "binary":
|
|
return I(this, e, n, length);
|
|
case "base64":
|
|
return E(this, e, n, length);
|
|
case "ucs2":
|
|
case "ucs-2":
|
|
case "utf16le":
|
|
case "utf-16le":
|
|
return k(this, e, n, length);
|
|
default:
|
|
if (a) throw new TypeError("Unknown encoding: " + i);
|
|
(i = ("" + i).toLowerCase()), (a = true);
|
|
}
|
|
}),
|
|
(s.prototype.toJSON = function t() {
|
|
return {
|
|
type: "Buffer",
|
|
data: Array.prototype.slice.call(this._arr || this, 0),
|
|
};
|
|
});
|
|
var ut = 4096;
|
|
(s.prototype.slice = function t(e, n) {
|
|
var i = this.length,
|
|
o;
|
|
if ((e = ~~e) < 0) {
|
|
if ((e += i) < 0) e = 0;
|
|
} else if (e > i) e = i;
|
|
if ((n = void 0 === n ? i : ~~n) < 0) {
|
|
if ((n += i) < 0) n = 0;
|
|
} else if (n > i) n = i;
|
|
if (n < e) n = e;
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(o = this.subarray(e, n)).__proto__ = s.prototype;
|
|
else {
|
|
var a = n - e;
|
|
o = new s(a, void 0);
|
|
for (var u = 0; u < a; ++u) o[u] = this[u + e];
|
|
}
|
|
return o;
|
|
}),
|
|
(s.prototype.readUIntLE = function t(e, n, i) {
|
|
if (((e |= 0), (n |= 0), !i)) z(e, n, this.length);
|
|
for (var o = this[e], a = 1, s = 0; ++s < n && (a *= 256);)
|
|
o += this[e + s] * a;
|
|
return o;
|
|
}),
|
|
(s.prototype.readUIntBE = function t(e, n, i) {
|
|
if (((e |= 0), (n |= 0), !i)) z(e, n, this.length);
|
|
for (var o = this[e + --n], a = 1; n > 0 && (a *= 256);)
|
|
o += this[e + --n] * a;
|
|
return o;
|
|
}),
|
|
(s.prototype.readUInt8 = function t(e, n) {
|
|
if (!n) z(e, 1, this.length);
|
|
return this[e];
|
|
}),
|
|
(s.prototype.readUInt16LE = function t(e, n) {
|
|
if (!n) z(e, 2, this.length);
|
|
return this[e] | (this[e + 1] << 8);
|
|
}),
|
|
(s.prototype.readUInt16BE = function t(e, n) {
|
|
if (!n) z(e, 2, this.length);
|
|
return (this[e] << 8) | this[e + 1];
|
|
}),
|
|
(s.prototype.readUInt32LE = function t(e, n) {
|
|
if (!n) z(e, 4, this.length);
|
|
return (
|
|
(this[e] | (this[e + 1] << 8) | (this[e + 2] << 16)) +
|
|
16777216 * this[e + 3]
|
|
);
|
|
}),
|
|
(s.prototype.readUInt32BE = function t(e, n) {
|
|
if (!n) z(e, 4, this.length);
|
|
return (
|
|
16777216 * this[e] +
|
|
((this[e + 1] << 16) | (this[e + 2] << 8) | this[e + 3])
|
|
);
|
|
}),
|
|
(s.prototype.readIntLE = function t(e, n, i) {
|
|
if (((e |= 0), (n |= 0), !i)) z(e, n, this.length);
|
|
for (var o = this[e], a = 1, s = 0; ++s < n && (a *= 256);)
|
|
o += this[e + s] * a;
|
|
if (o >= (a *= 128)) o -= Math.pow(2, 8 * n);
|
|
return o;
|
|
}),
|
|
(s.prototype.readIntBE = function t(e, n, i) {
|
|
if (((e |= 0), (n |= 0), !i)) z(e, n, this.length);
|
|
for (var o = n, a = 1, s = this[e + --o]; o > 0 && (a *= 256);)
|
|
s += this[e + --o] * a;
|
|
if (s >= (a *= 128)) s -= Math.pow(2, 8 * n);
|
|
return s;
|
|
}),
|
|
(s.prototype.readInt8 = function t(e, n) {
|
|
if (!n) z(e, 1, this.length);
|
|
if (!(128 & this[e])) return this[e];
|
|
else return -1 * (255 - this[e] + 1);
|
|
}),
|
|
(s.prototype.readInt16LE = function t(e, n) {
|
|
if (!n) z(e, 2, this.length);
|
|
var i = this[e] | (this[e + 1] << 8);
|
|
return 32768 & i ? 4294901760 | i : i;
|
|
}),
|
|
(s.prototype.readInt16BE = function t(e, n) {
|
|
if (!n) z(e, 2, this.length);
|
|
var i = this[e + 1] | (this[e] << 8);
|
|
return 32768 & i ? 4294901760 | i : i;
|
|
}),
|
|
(s.prototype.readInt32LE = function t(e, n) {
|
|
if (!n) z(e, 4, this.length);
|
|
return (
|
|
this[e] |
|
|
(this[e + 1] << 8) |
|
|
(this[e + 2] << 16) |
|
|
(this[e + 3] << 24)
|
|
);
|
|
}),
|
|
(s.prototype.readInt32BE = function t(e, n) {
|
|
if (!n) z(e, 4, this.length);
|
|
return (
|
|
(this[e] << 24) |
|
|
(this[e + 1] << 16) |
|
|
(this[e + 2] << 8) |
|
|
this[e + 3]
|
|
);
|
|
}),
|
|
(s.prototype.readFloatLE = function t(e, n) {
|
|
if (!n) z(e, 4, this.length);
|
|
return at.read(this, e, true, 23, 4);
|
|
}),
|
|
(s.prototype.readFloatBE = function t(e, n) {
|
|
if (!n) z(e, 4, this.length);
|
|
return at.read(this, e, false, 23, 4);
|
|
}),
|
|
(s.prototype.readDoubleLE = function t(e, n) {
|
|
if (!n) z(e, 8, this.length);
|
|
return at.read(this, e, true, 52, 8);
|
|
}),
|
|
(s.prototype.readDoubleBE = function t(e, n) {
|
|
if (!n) z(e, 8, this.length);
|
|
return at.read(this, e, false, 52, 8);
|
|
}),
|
|
(s.prototype.writeUIntLE = function t(e, n, i, o) {
|
|
if (((e = +e), (n |= 0), (i |= 0), !o)) {
|
|
var a;
|
|
U(this, e, n, i, Math.pow(2, 8 * i) - 1, 0);
|
|
}
|
|
var s = 1,
|
|
u = 0;
|
|
for (this[n] = 255 & e; ++u < i && (s *= 256);)
|
|
this[n + u] = (e / s) & 255;
|
|
return n + i;
|
|
}),
|
|
(s.prototype.writeUIntBE = function t(e, n, i, o) {
|
|
if (((e = +e), (n |= 0), (i |= 0), !o)) {
|
|
var a;
|
|
U(this, e, n, i, Math.pow(2, 8 * i) - 1, 0);
|
|
}
|
|
var s = i - 1,
|
|
u = 1;
|
|
for (this[n + s] = 255 & e; --s >= 0 && (u *= 256);)
|
|
this[n + s] = (e / u) & 255;
|
|
return n + i;
|
|
}),
|
|
(s.prototype.writeUInt8 = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 1, 255, 0);
|
|
if (!s.TYPED_ARRAY_SUPPORT) e = Math.floor(e);
|
|
return (this[n] = 255 & e), n + 1;
|
|
}),
|
|
(s.prototype.writeUInt16LE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 2, 65535, 0);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = 255 & e), (this[n + 1] = e >>> 8);
|
|
else H(this, e, n, true);
|
|
return n + 2;
|
|
}),
|
|
(s.prototype.writeUInt16BE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 2, 65535, 0);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = e >>> 8), (this[n + 1] = 255 & e);
|
|
else H(this, e, n, false);
|
|
return n + 2;
|
|
}),
|
|
(s.prototype.writeUInt32LE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 4, 4294967295, 0);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n + 3] = e >>> 24),
|
|
(this[n + 2] = e >>> 16),
|
|
(this[n + 1] = e >>> 8),
|
|
(this[n] = 255 & e);
|
|
else $(this, e, n, true);
|
|
return n + 4;
|
|
}),
|
|
(s.prototype.writeUInt32BE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 4, 4294967295, 0);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = e >>> 24),
|
|
(this[n + 1] = e >>> 16),
|
|
(this[n + 2] = e >>> 8),
|
|
(this[n + 3] = 255 & e);
|
|
else $(this, e, n, false);
|
|
return n + 4;
|
|
}),
|
|
(s.prototype.writeIntLE = function t(e, n, i, o) {
|
|
if (((e = +e), (n |= 0), !o)) {
|
|
var a = Math.pow(2, 8 * i - 1);
|
|
U(this, e, n, i, a - 1, -a);
|
|
}
|
|
var s = 0,
|
|
u = 1,
|
|
l = 0;
|
|
for (this[n] = 255 & e; ++s < i && (u *= 256);) {
|
|
if (e < 0 && 0 === l && 0 !== this[n + s - 1]) l = 1;
|
|
this[n + s] = (((e / u) >> 0) - l) & 255;
|
|
}
|
|
return n + i;
|
|
}),
|
|
(s.prototype.writeIntBE = function t(e, n, i, o) {
|
|
if (((e = +e), (n |= 0), !o)) {
|
|
var a = Math.pow(2, 8 * i - 1);
|
|
U(this, e, n, i, a - 1, -a);
|
|
}
|
|
var s = i - 1,
|
|
u = 1,
|
|
l = 0;
|
|
for (this[n + s] = 255 & e; --s >= 0 && (u *= 256);) {
|
|
if (e < 0 && 0 === l && 0 !== this[n + s + 1]) l = 1;
|
|
this[n + s] = (((e / u) >> 0) - l) & 255;
|
|
}
|
|
return n + i;
|
|
}),
|
|
(s.prototype.writeInt8 = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 1, 127, -128);
|
|
if (!s.TYPED_ARRAY_SUPPORT) e = Math.floor(e);
|
|
if (e < 0) e = 255 + e + 1;
|
|
return (this[n] = 255 & e), n + 1;
|
|
}),
|
|
(s.prototype.writeInt16LE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 2, 32767, -32768);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = 255 & e), (this[n + 1] = e >>> 8);
|
|
else H(this, e, n, true);
|
|
return n + 2;
|
|
}),
|
|
(s.prototype.writeInt16BE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i)) U(this, e, n, 2, 32767, -32768);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = e >>> 8), (this[n + 1] = 255 & e);
|
|
else H(this, e, n, false);
|
|
return n + 2;
|
|
}),
|
|
(s.prototype.writeInt32LE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i))
|
|
U(this, e, n, 4, 2147483647, -2147483648);
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = 255 & e),
|
|
(this[n + 1] = e >>> 8),
|
|
(this[n + 2] = e >>> 16),
|
|
(this[n + 3] = e >>> 24);
|
|
else $(this, e, n, true);
|
|
return n + 4;
|
|
}),
|
|
(s.prototype.writeInt32BE = function t(e, n, i) {
|
|
if (((e = +e), (n |= 0), !i))
|
|
U(this, e, n, 4, 2147483647, -2147483648);
|
|
if (e < 0) e = 4294967295 + e + 1;
|
|
if (s.TYPED_ARRAY_SUPPORT)
|
|
(this[n] = e >>> 24),
|
|
(this[n + 1] = e >>> 16),
|
|
(this[n + 2] = e >>> 8),
|
|
(this[n + 3] = 255 & e);
|
|
else $(this, e, n, false);
|
|
return n + 4;
|
|
}),
|
|
(s.prototype.writeFloatLE = function t(e, n, i) {
|
|
return Y(this, e, n, true, i);
|
|
}),
|
|
(s.prototype.writeFloatBE = function t(e, n, i) {
|
|
return Y(this, e, n, false, i);
|
|
}),
|
|
(s.prototype.writeDoubleLE = function t(e, n, i) {
|
|
return W(this, e, n, true, i);
|
|
}),
|
|
(s.prototype.writeDoubleBE = function t(e, n, i) {
|
|
return W(this, e, n, false, i);
|
|
}),
|
|
(s.prototype.copy = function copy(t, e, n, i) {
|
|
if (!n) n = 0;
|
|
if (!i && 0 !== i) i = this.length;
|
|
if (e >= t.length) e = t.length;
|
|
if (!e) e = 0;
|
|
if (i > 0 && i < n) i = n;
|
|
if (i === n) return 0;
|
|
if (0 === t.length || 0 === this.length) return 0;
|
|
if (e < 0) throw new RangeError("targetStart out of bounds");
|
|
if (n < 0 || n >= this.length)
|
|
throw new RangeError("sourceStart out of bounds");
|
|
if (i < 0) throw new RangeError("sourceEnd out of bounds");
|
|
if (i > this.length) i = this.length;
|
|
if (t.length - e < i - n) i = t.length - e + n;
|
|
var o = i - n,
|
|
a;
|
|
if (this === t && n < e && e < i)
|
|
for (a = o - 1; a >= 0; --a) t[a + e] = this[a + n];
|
|
else if (o < 1e3 || !s.TYPED_ARRAY_SUPPORT)
|
|
for (a = 0; a < o; ++a) t[a + e] = this[a + n];
|
|
else Uint8Array.prototype.set.call(t, this.subarray(n, n + o), e);
|
|
return o;
|
|
}),
|
|
(s.prototype.fill = function t(e, n, i, o) {
|
|
if ("string" == typeof e) {
|
|
if ("string" == typeof n) (o = n), (n = 0), (i = this.length);
|
|
else if ("string" == typeof i) (o = i), (i = this.length);
|
|
if (1 === e.length) {
|
|
var a = e.charCodeAt(0);
|
|
if (a < 256) e = a;
|
|
}
|
|
if (void 0 !== o && "string" != typeof o)
|
|
throw new TypeError("encoding must be a string");
|
|
if ("string" == typeof o && !s.isEncoding(o))
|
|
throw new TypeError("Unknown encoding: " + o);
|
|
} else if ("number" == typeof e) e &= 255;
|
|
if (n < 0 || this.length < n || this.length < i)
|
|
throw new RangeError("Out of range index");
|
|
if (i <= n) return this;
|
|
if (((n >>>= 0), (i = void 0 === i ? this.length : i >>> 0), !e))
|
|
e = 0;
|
|
var u;
|
|
if ("number" == typeof e) for (u = n; u < i; ++u) this[u] = e;
|
|
else {
|
|
var l = s.isBuffer(e) ? e : X(new s(e, o).toString()),
|
|
f = l.length;
|
|
for (u = 0; u < i - n; ++u) this[u + n] = l[u % f];
|
|
}
|
|
return this;
|
|
});
|
|
var lt = /[^+\/0-9A-Za-z-_]/g;
|
|
}).call(e, n(41));
|
|
},
|
|
427: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(189).instance();
|
|
i.registerAnimation(n(428)),
|
|
i.registerAnimation(n(431)),
|
|
i.registerAnimation(n(190));
|
|
},
|
|
428: function (t, e, n) {
|
|
"use strict";
|
|
function i(t, e) {
|
|
(this.info = t), (this.hint = e), (this.timeoutId = null);
|
|
}
|
|
var o = n(429);
|
|
(t.exports = i),
|
|
(i.isMatch = function (t) {
|
|
return t && "counter" === t.name;
|
|
}),
|
|
(i.create = function (t, e) {
|
|
return new i(t, e);
|
|
}),
|
|
(i.prototype.init = function init() {
|
|
var t = this.info.element;
|
|
if (!this.countUp && t) {
|
|
var e = /(\D*)(\d+(?:([.,])(\d+))?)(.*)/.exec(t.innerText),
|
|
n = 1,
|
|
i = 2,
|
|
a = 3,
|
|
s = 4,
|
|
u = 5;
|
|
if (null !== e && e[i] && !(e[i].length > 15)) {
|
|
var l = e[i];
|
|
if ("," === e[a]) l = l.replace(",", ".");
|
|
if ((l = Number(l)) && !isNaN(l) && isFinite(l)) {
|
|
if (this.hint) this.hint.hintBrowser(this.info);
|
|
var f = 0;
|
|
if (e[s]) f = e[s].length;
|
|
var c = {
|
|
element: t,
|
|
prefix: e[n],
|
|
decimal: e[a],
|
|
decimals: f,
|
|
suffix: e[u],
|
|
startVal: 0,
|
|
endVal: l,
|
|
duration: this.info.durationRaw,
|
|
cycle: this.info.animationCycle,
|
|
separator: "",
|
|
};
|
|
this.countUp = new o(c);
|
|
}
|
|
}
|
|
}
|
|
}),
|
|
(i.prototype.start = function t() {
|
|
if (this.countUp) {
|
|
if ((this.countUp.reset(), this._timeoutId))
|
|
clearTimeout(this._timeoutId);
|
|
var e = function () {
|
|
(this._timeoutId = null), this.countUp.start();
|
|
}.bind(this),
|
|
n = this.info.delay;
|
|
if (isNaN(n)) n = 0;
|
|
if (!n) return e(), void 0;
|
|
this._timeoutId = setTimeout(e, n);
|
|
}
|
|
}),
|
|
(i.prototype.startOut = function t() {
|
|
if (this._timeoutId)
|
|
clearTimeout(this._timeoutId), (this._timeoutId = null);
|
|
}),
|
|
(i.prototype.reset = function t() {
|
|
if (this.countUp) this.countUp.reset();
|
|
}),
|
|
(i.prototype.isInOutAnimation = function t() {
|
|
return true;
|
|
}),
|
|
(i.prototype.needOutAnimation = function t() {
|
|
return false;
|
|
}),
|
|
(i.prototype.clear = function t() {
|
|
if (this.hint) this.hint.removeHint(this.info);
|
|
}),
|
|
(i.prototype.getTime = function t() {
|
|
if (!this.info) return 0;
|
|
var e = this.info.duration,
|
|
n = this.info.delay;
|
|
if (isNaN(n)) n = 0;
|
|
return n + e;
|
|
}),
|
|
(i.prototype.getOutTime = function t() {
|
|
return 0;
|
|
});
|
|
},
|
|
429: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
this.initialize(t);
|
|
}
|
|
function o(countUp, t, e) {
|
|
if (countUp) {
|
|
if (((t = Number(t)), isNaN(t) || !isFinite(t) || 0 === t)) t = 1;
|
|
var n = 0,
|
|
i = function () {
|
|
if (++n < t) countUp.reset(), countUp.start(i);
|
|
else if ("function" == typeof e) e();
|
|
};
|
|
countUp.start(i);
|
|
}
|
|
}
|
|
n(430),
|
|
(i.prototype.initialize = function t(e) {
|
|
if (!this.countUp && e.element) {
|
|
var n = e.startVal,
|
|
i = e.endVal,
|
|
o = e.decimals,
|
|
a = e.duration;
|
|
if ((n || 0 == +n) && (i || 0 == +i)) {
|
|
if (a) if (((a = Number(a) / 1e3), isNaN(a))) a = void 0;
|
|
(this.cycle = e.cycle),
|
|
(this.countUp = new CountUp(e.element, n, i, o, a, e)),
|
|
(this.started = false);
|
|
}
|
|
}
|
|
}),
|
|
(i.prototype.reset = function t() {
|
|
if (((this.started = false), this.countUp)) this.countUp.reset();
|
|
}),
|
|
(i.prototype.start = function t() {
|
|
if (this.countUp && !this.started)
|
|
(this.started = true), o(this.countUp, this.cycle);
|
|
}),
|
|
(t.exports = i);
|
|
},
|
|
430: function (t, e) {
|
|
var e = void 0,
|
|
t = void 0;
|
|
(function () {
|
|
!(function (n, factory) {
|
|
if ("function" == typeof define && define.amd) define(factory);
|
|
else if ("object" == typeof e) t.exports = factory(require, e, t);
|
|
else n.CountUp = factory();
|
|
})(this, function (t, e, n) {
|
|
var CountUp;
|
|
return function (t, e, n, i, o, a) {
|
|
function s(t) {
|
|
var e, n, i, o, a, s;
|
|
if (
|
|
((t = t.toFixed(f.decimals)),
|
|
(n = (e = (t += "").split("."))[0]),
|
|
(i = e.length > 1 ? f.options.decimal + e[1] : ""),
|
|
f.options.useGrouping)
|
|
) {
|
|
for (o = "", a = 0, s = n.length; a < s; ++a) {
|
|
if (0 !== a && a % 3 == 0) o = f.options.separator + o;
|
|
o = n[s - a - 1] + o;
|
|
}
|
|
n = o;
|
|
}
|
|
if (f.options.numerals.length)
|
|
(n = n.replace(/[0-9]/g, function (t) {
|
|
return f.options.numerals[+t];
|
|
})),
|
|
(i = i.replace(/[0-9]/g, function (t) {
|
|
return f.options.numerals[+t];
|
|
}));
|
|
return f.options.prefix + n + i + f.options.suffix;
|
|
}
|
|
function u(t, e, n, d) {
|
|
return (n * (-Math.pow(2, (-10 * t) / d) + 1) * 1024) / 1023 + e;
|
|
}
|
|
function l(t) {
|
|
return "number" == typeof t && !isNaN(t);
|
|
}
|
|
var f = this;
|
|
if (
|
|
((f.version = function () {
|
|
return "1.9.2";
|
|
}),
|
|
(f.options = {
|
|
useEasing: true,
|
|
useGrouping: true,
|
|
separator: ",",
|
|
decimal: ".",
|
|
easingFn: u,
|
|
formattingFn: s,
|
|
prefix: "",
|
|
suffix: "",
|
|
numerals: [],
|
|
}),
|
|
a && "object" == typeof a)
|
|
)
|
|
for (var c in f.options)
|
|
if (a.hasOwnProperty(c) && null !== a[c]) f.options[c] = a[c];
|
|
if ("" === f.options.separator) f.options.useGrouping = false;
|
|
else f.options.separator = "" + f.options.separator;
|
|
for (
|
|
var h = 0, p = ["webkit", "moz", "ms", "o"], m = 0;
|
|
m < p.length && !window.requestAnimationFrame;
|
|
++m
|
|
)
|
|
(window.requestAnimationFrame =
|
|
window[p[m] + "RequestAnimationFrame"]),
|
|
(window.cancelAnimationFrame =
|
|
window[p[m] + "CancelAnimationFrame"] ||
|
|
window[p[m] + "CancelRequestAnimationFrame"]);
|
|
if (!window.requestAnimationFrame)
|
|
window.requestAnimationFrame = function (t, e) {
|
|
var n = new Date().getTime(),
|
|
i = Math.max(0, 16 - (n - h)),
|
|
id = window.setTimeout(function () {
|
|
t(n + i);
|
|
}, i);
|
|
return (h = n + i), id;
|
|
};
|
|
if (!window.cancelAnimationFrame)
|
|
window.cancelAnimationFrame = function (id) {
|
|
clearTimeout(id);
|
|
};
|
|
if (
|
|
((f.initialize = function () {
|
|
if (f.initialized) return true;
|
|
if (
|
|
((f.error = ""),
|
|
(f.d = "string" == typeof t ? document.getElementById(t) : t),
|
|
!f.d)
|
|
)
|
|
return (
|
|
(f.error = "[CountUp] target is null or undefined"), false
|
|
);
|
|
if (
|
|
((f.startVal = Number(e)),
|
|
(f.endVal = Number(n)),
|
|
l(f.startVal) && l(f.endVal))
|
|
)
|
|
return (
|
|
(f.decimals = Math.max(0, i || 0)),
|
|
(f.dec = Math.pow(10, f.decimals)),
|
|
(f.duration = 1e3 * Number(o) || 2e3),
|
|
(f.countDown = f.startVal > f.endVal),
|
|
(f.frameVal = f.startVal),
|
|
(f.initialized = true),
|
|
true
|
|
);
|
|
else
|
|
return (
|
|
(f.error =
|
|
"[CountUp] startVal (" +
|
|
e +
|
|
") or endVal (" +
|
|
n +
|
|
") is not a number"),
|
|
false
|
|
);
|
|
}),
|
|
(f.printValue = function (t) {
|
|
var e = f.options.formattingFn(t);
|
|
if ("INPUT" === f.d.tagName) this.d.value = e;
|
|
else if ("text" === f.d.tagName || "tspan" === f.d.tagName)
|
|
this.d.textContent = e;
|
|
else this.d.innerHTML = e;
|
|
}),
|
|
(f.count = function (t) {
|
|
if (!f.startTime) f.startTime = t;
|
|
f.timestamp = t;
|
|
var e = t - f.startTime;
|
|
if (((f.remaining = f.duration - e), f.options.useEasing))
|
|
if (f.countDown)
|
|
f.frameVal =
|
|
f.startVal -
|
|
f.options.easingFn(e, 0, f.startVal - f.endVal, f.duration);
|
|
else
|
|
f.frameVal = f.options.easingFn(
|
|
e,
|
|
f.startVal,
|
|
f.endVal - f.startVal,
|
|
f.duration
|
|
);
|
|
else if (f.countDown)
|
|
f.frameVal =
|
|
f.startVal - (f.startVal - f.endVal) * (e / f.duration);
|
|
else
|
|
f.frameVal =
|
|
f.startVal + (f.endVal - f.startVal) * (e / f.duration);
|
|
if (f.countDown)
|
|
f.frameVal = f.frameVal < f.endVal ? f.endVal : f.frameVal;
|
|
else f.frameVal = f.frameVal > f.endVal ? f.endVal : f.frameVal;
|
|
if (
|
|
((f.frameVal = Math.round(f.frameVal * f.dec) / f.dec),
|
|
f.printValue(f.frameVal),
|
|
e < f.duration)
|
|
)
|
|
f.rAF = requestAnimationFrame(f.count);
|
|
else if (f.callback) f.callback();
|
|
}),
|
|
(f.start = function (t) {
|
|
if (f.initialize())
|
|
(f.callback = t), (f.rAF = requestAnimationFrame(f.count));
|
|
}),
|
|
(f.pauseResume = function () {
|
|
if (!f.paused) (f.paused = true), cancelAnimationFrame(f.rAF);
|
|
else
|
|
(f.paused = false),
|
|
delete f.startTime,
|
|
(f.duration = f.remaining),
|
|
(f.startVal = f.frameVal),
|
|
requestAnimationFrame(f.count);
|
|
}),
|
|
(f.reset = function () {
|
|
if (
|
|
((f.paused = false),
|
|
delete f.startTime,
|
|
(f.initialized = false),
|
|
f.initialize())
|
|
)
|
|
cancelAnimationFrame(f.rAF), f.printValue(f.startVal);
|
|
}),
|
|
(f.update = function (t) {
|
|
if (f.initialize()) {
|
|
if (!l((t = Number(t))))
|
|
return (
|
|
(f.error =
|
|
"[CountUp] update() - new endVal is not a number: " + t),
|
|
void 0
|
|
);
|
|
if (((f.error = ""), t !== f.frameVal))
|
|
cancelAnimationFrame(f.rAF),
|
|
(f.paused = false),
|
|
delete f.startTime,
|
|
(f.startVal = f.frameVal),
|
|
(f.endVal = t),
|
|
(f.countDown = f.startVal > f.endVal),
|
|
(f.rAF = requestAnimationFrame(f.count));
|
|
}
|
|
}),
|
|
f.initialize())
|
|
)
|
|
f.printValue(f.startVal);
|
|
};
|
|
});
|
|
}).call(window);
|
|
},
|
|
431: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
o.apply(this, arguments),
|
|
(this.backstageClass = ["backstage", "u-backstage-hidden"]);
|
|
}
|
|
var o = n(190);
|
|
Object.assign(i.prototype, o.prototype),
|
|
(t.exports = i),
|
|
(i.isMatch = function (t) {
|
|
var e = ((t && t.name) || "").toLowerCase();
|
|
return (
|
|
[
|
|
"fadein",
|
|
"flipin",
|
|
"bouncein",
|
|
"jackinthebox",
|
|
"lightspeedin",
|
|
"customanimationin",
|
|
].indexOf(e) > -1
|
|
);
|
|
}),
|
|
(i.create = function (t, e) {
|
|
return new i(t, e);
|
|
});
|
|
},
|
|
469: function (t, e) { },
|
|
485: function (t, e, n) {
|
|
"use strict";
|
|
function i(t, e) {
|
|
if ("string" != typeof t) return 0;
|
|
var n = new u().replace(t, e).expr;
|
|
if ("" === n.trim()) return 0;
|
|
o(n);
|
|
try {
|
|
var i, l;
|
|
return s(new Function('"use strict";return (' + n + ");")(), 4);
|
|
} catch (e) {
|
|
return a(e, t);
|
|
}
|
|
}
|
|
function o(t) {
|
|
var e = /[^-()\d\s/*+.]+|\/\/|\/\*/g.exec(t),
|
|
n = 20,
|
|
i;
|
|
if (e) {
|
|
var o = {
|
|
messageKey: "#FormCalc_UnexpectedToken",
|
|
expression: (i = e[0].substring(0, n)),
|
|
position: e.index,
|
|
};
|
|
throw Object.assign(
|
|
new Error("Unexpected token '" + i + "'", { cause: o }),
|
|
{ args: o }
|
|
);
|
|
}
|
|
}
|
|
function a(t, e) {
|
|
var n = { messageKey: "#FormCalc_EvaluationFailed", expression: e };
|
|
throw Object.assign(new Error("Evaluation failed", { cause: n }), {
|
|
args: n,
|
|
});
|
|
}
|
|
function s(t, e) {
|
|
if (((t = Number(t)), (e = Number(e)), isNaN(t) || !isFinite(t)))
|
|
return t;
|
|
var n = t.toString().split("e"),
|
|
i = n[0],
|
|
o = n[1] || 0,
|
|
a,
|
|
s,
|
|
u = Math.round(Number(i + "e" + (+o + e)))
|
|
.toString()
|
|
.split("e")[0],
|
|
l = n[1] || 0;
|
|
return Number(u + "e" + (+l - e));
|
|
}
|
|
var u = n(299);
|
|
t.exports.evaluate = i;
|
|
},
|
|
486: function (t, e, n) {
|
|
"use strict";
|
|
function i(el) {
|
|
var t = el.getAttribute("name"),
|
|
type;
|
|
if (!t) return t;
|
|
if (((t = t.trim()), "SELECT" === el.tagName)) return o(t);
|
|
if ("checkbox" === el.getAttribute("type")) return o(t);
|
|
else return t;
|
|
}
|
|
function o(t) {
|
|
if (!t) return t;
|
|
var e = t.lastIndexOf("[][]");
|
|
if (e > 0 && e + 4 === t.length) return t.substring(0, t.length - 4);
|
|
if ((e = t.lastIndexOf("[]")) > 0 && e + 2 === t.length)
|
|
return t.substring(0, t.length - 2);
|
|
else return t;
|
|
}
|
|
function a(el) {
|
|
if ("OPTION" === el.tagName) return el.getAttribute("data-calc");
|
|
var type = el.getAttribute("type");
|
|
if ("number" === type || "range" === type) return el.value;
|
|
if ("radio" === type) return el.getAttribute("data-calc");
|
|
if ("checkbox" === type && null !== el.getAttribute("data-calc"))
|
|
return el.getAttribute("data-calc");
|
|
if ("checkbox" === type) return el.value;
|
|
else return;
|
|
}
|
|
function s(el) {
|
|
return Number(a(el));
|
|
}
|
|
function u(el) {
|
|
if ("OPTION" === el.tagName) return el.selected;
|
|
var type = el.getAttribute("type");
|
|
if ("radio" === type || "checkbox" === type) return el.checked;
|
|
else return true;
|
|
}
|
|
function l(el, t) {
|
|
if (((t = t || 0), u(el))) return s(el);
|
|
else return t;
|
|
}
|
|
var f = (t.exports = function t(form) {
|
|
(this.fields = []),
|
|
this.collectInputs(
|
|
form.querySelectorAll("[type=number], [type=range]")
|
|
),
|
|
this.collectInputs(form.querySelectorAll("[type=radio]")),
|
|
this.collectInputs(form.querySelectorAll('[type="checkbox"]')),
|
|
this.collectSelects(form.querySelectorAll("select"));
|
|
});
|
|
(f.prototype.getScope = function t() {
|
|
return this.fields.reduce(function (t, e) {
|
|
if (!e || !e.name) return t;
|
|
if (!t[e.name]) t[e.name] = 0;
|
|
return (t[e.name] += e.value), t;
|
|
}, {});
|
|
}),
|
|
(f.prototype.addField = function t(field) {
|
|
return this.fields.push(field), field;
|
|
}),
|
|
(f.prototype.collectInputs = function (t) {
|
|
for (var e = 0; e < t.length; e++)
|
|
this.addField({
|
|
name: i(t[e]),
|
|
value: l(t[e], 0),
|
|
rawValue: a(t[e]),
|
|
});
|
|
}),
|
|
(f.prototype.collectSelects = function (t) {
|
|
for (var e = 0; e < t.length; e++)
|
|
this.collectOptions(i(t[e]), t[e].querySelectorAll("option"));
|
|
}),
|
|
(f.prototype.collectOptions = function (t, e) {
|
|
for (var n = 0; n < e.length; n++)
|
|
this.addField({ name: t, value: l(e[n], 0), rawValue: a(e[n]) });
|
|
});
|
|
},
|
|
487: function (t, e, n) {
|
|
"use strict";
|
|
function i(t, e, n) {
|
|
var i = t.find(".u-form-progress-step");
|
|
i.removeClass("active done"),
|
|
o(i.find(".u-form-progress-icon"), "default"),
|
|
o(i.find(".u-form-progress-icon"), "step");
|
|
var a = t.find(".u-form-progress-step").eq(n);
|
|
a.addClass("active");
|
|
var s = a.prevAll(".u-form-progress-step");
|
|
s.addClass("done"), o(s.find(".u-form-progress-icon"), "done");
|
|
}
|
|
function o(icon, type) {
|
|
(type = type || "default"),
|
|
icon.each(function () {
|
|
var t = $(this),
|
|
e = t.attr("data-step-icon-" + type);
|
|
if (e) t.html(e);
|
|
});
|
|
}
|
|
function a(t, e, n) {
|
|
var i = t.find(".u-form-progress-bar"),
|
|
o =
|
|
"calc((100% - var(--step-icon-size)) / " +
|
|
(e.length - 1) +
|
|
" * " +
|
|
n +
|
|
")";
|
|
i.css("width", o);
|
|
}
|
|
var FormProgress;
|
|
t.exports.update = function (form, t) {
|
|
if (form.length) {
|
|
var e = form.find(".u-form-progress"),
|
|
n = form.find(".u-carousel-inner").children();
|
|
if (void 0 === t) t = n.filter(".u-active, .active").index();
|
|
a(e, n, t), i(e, n, t);
|
|
}
|
|
};
|
|
},
|
|
488: function (t, e, n) {
|
|
"use strict";
|
|
var i;
|
|
t.exports.update = function (form, t) {
|
|
var e = form.find(".u-slide");
|
|
if (void 0 === t) t = e.filter(".u-active, .active").index();
|
|
var n = form.find(".u-btn-submit, .u-btn-step"),
|
|
i = n.filter(".u-btn-submit"),
|
|
o = n.filter(".u-btn-step-next"),
|
|
a = n.filter(".u-btn-step-prev");
|
|
if ((n.show(), 0 === t)) a.hide();
|
|
if (t === e.length - 1) o.hide(), i.show();
|
|
if (t < e.length - 1) o.show(), i.hide();
|
|
};
|
|
},
|
|
489: function (t, e, n) {
|
|
"use strict";
|
|
var FormFileType = n(96),
|
|
FormFileAccept = (t.exports = {});
|
|
(FormFileAccept[FormFileType.IMAGES] =
|
|
".bmp,.dng,.eps,.gif,.jpg,.jpeg,.png,.ps,.raw,.svg,.tga,.tif,.tiff"),
|
|
(FormFileAccept[FormFileType.DOCUMENTS] =
|
|
".ai,.cdr,.csv,.doc,.docb,.docx,.dot,.dotx,.dwg,.eps,.epub,.fla,.gpx,.ical,.icalendar,.ics,.ifb,.indd,.ipynb,.key,.kml,.kmz,.mobi,.mtf,.mtx,.numbers,.odg,.odp,.ods,.odt,.otp,.ots,.ott,.oxps,.pages,.pdf,.pdn,.pkg,.pot,.potx,.pps,.ppsx,.ppt,.pptx,.psd,.pub,.rtf,.sldx,.txt,.vcf,.xcf,.xls,.xlsx,.xlt,.xltx,.xlw,.xps,.zip"),
|
|
(FormFileAccept[FormFileType.VIDEO] =
|
|
".3gp,.avi,.divx,.flv,.m1v,.m2ts,.m4v,.mkv,.mov,.mp4,.mpe,.mpeg,.mpg,.mxf,.ogv,.vob.webm,.wmv,.xvid"),
|
|
(FormFileAccept[FormFileType.AUDIO] =
|
|
".aac,.aif,.aiff,.flac,.m4a,.mp3,.wav,.wma");
|
|
},
|
|
56: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(8);
|
|
(t.exports = i.md = i.md || {}), (i.md.algorithms = i.md.algorithms || {});
|
|
},
|
|
673: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(674),
|
|
bootstrap = {};
|
|
(bootstrap.Util = (function (t) {
|
|
function e(t) {
|
|
return t && "object" == typeof t && "default" in t ? t : { default: t };
|
|
}
|
|
function n() {
|
|
if (window.QUnit) return false;
|
|
var el = document.createElement("bootstrap");
|
|
for (var t in h) if (void 0 !== el.style[t]) return h[t];
|
|
return false;
|
|
}
|
|
function i(t) {
|
|
if (null == t) return "" + t;
|
|
else
|
|
return {}.toString
|
|
.call(t)
|
|
.match(/\s([a-z]+)/i)[1]
|
|
.toLowerCase();
|
|
}
|
|
function o() {
|
|
return {
|
|
bindType: l,
|
|
delegateType: l,
|
|
handle: function t(e) {
|
|
if (u["default"](e.target).is(this))
|
|
return e.handleObj.handler.apply(this, arguments);
|
|
},
|
|
};
|
|
}
|
|
function a(t) {
|
|
var e = this,
|
|
n = false;
|
|
return (
|
|
u["default"](this).one(Util.TRANSITION_END, function () {
|
|
n = true;
|
|
}),
|
|
setTimeout(function () {
|
|
if (!n) Util.triggerTransitionEnd(e);
|
|
}, t),
|
|
this
|
|
);
|
|
}
|
|
function s() {
|
|
(l = n()),
|
|
(u["default"].fn.emulateTransitionEnd = a),
|
|
(u["default"].event.special[Util.TRANSITION_END] = o());
|
|
}
|
|
var u = e(t),
|
|
l = false,
|
|
f = 1e6,
|
|
c = 1e3,
|
|
h = {
|
|
WebkitTransition: "webkitTransitionEnd",
|
|
MozTransition: "transitionend",
|
|
OTransition: "oTransitionEnd otransitionend",
|
|
transition: "transitionend",
|
|
},
|
|
Util = {
|
|
TRANSITION_END: "bsTransitionEnd",
|
|
getUID: function t(e) {
|
|
do {
|
|
e += ~~(Math.random() * f);
|
|
} while (document.getElementById(e));
|
|
return e;
|
|
},
|
|
getSelectorFromElement: function t(e) {
|
|
var selector = e.getAttribute("data-u-target");
|
|
if (!selector || "#" === selector) {
|
|
var n = e.getAttribute("href");
|
|
selector = n && "#" !== n ? n.trim() : "";
|
|
}
|
|
try {
|
|
return document.querySelector(selector) ? selector : null;
|
|
} catch (t) {
|
|
return null;
|
|
}
|
|
},
|
|
getTransitionDurationFromElement: function t(e) {
|
|
if (!e) return 0;
|
|
var n = u["default"](e).css("transition-duration"),
|
|
i = u["default"](e).css("transition-delay"),
|
|
o = parseFloat(n),
|
|
a = parseFloat(i);
|
|
if (!o && !a) return 0;
|
|
else
|
|
return (
|
|
(n = n.split(",")[0]),
|
|
(i = i.split(",")[0]),
|
|
(parseFloat(n) + parseFloat(i)) * c
|
|
);
|
|
},
|
|
reflow: function t(e) {
|
|
return e.offsetHeight;
|
|
},
|
|
triggerTransitionEnd: function t(e) {
|
|
u["default"](e).trigger(l);
|
|
},
|
|
supportsTransitionEnd: function t() {
|
|
return Boolean(l);
|
|
},
|
|
isElement: function t(e) {
|
|
return (e[0] || e).nodeType;
|
|
},
|
|
typeCheckConfig: function t(e, n, o) {
|
|
for (var a in o)
|
|
if (Object.prototype.hasOwnProperty.call(o, a)) {
|
|
var s = o[a],
|
|
u = n[a],
|
|
l = u && Util.isElement(u) ? "element" : i(u);
|
|
if (!new RegExp(s).test(l))
|
|
throw new Error(
|
|
e.toUpperCase() +
|
|
": " +
|
|
'Option "' +
|
|
a +
|
|
'" provided type "' +
|
|
l +
|
|
'" ' +
|
|
'but expected type "' +
|
|
s +
|
|
'".'
|
|
);
|
|
}
|
|
},
|
|
findShadowRoot: function t(e) {
|
|
if (!document.documentElement.attachShadow) return null;
|
|
if ("function" == typeof e.getRootNode) {
|
|
var n = e.getRootNode();
|
|
return n instanceof ShadowRoot ? n : null;
|
|
}
|
|
if (e instanceof ShadowRoot) return e;
|
|
if (!e.parentNode) return null;
|
|
else return Util.findShadowRoot(e.parentNode);
|
|
},
|
|
};
|
|
return s(), Util;
|
|
})($)),
|
|
(bootstrap.Carousel = (function (t, Util) {
|
|
function e(t) {
|
|
return t && "object" == typeof t && "default" in t
|
|
? t
|
|
: { default: t };
|
|
}
|
|
function n(t, props) {
|
|
for (var e = 0; e < props.length; e++) {
|
|
var n = props[e];
|
|
if (
|
|
((n.enumerable = n.enumerable || false),
|
|
(n.configurable = true),
|
|
"value" in n)
|
|
)
|
|
n.writable = true;
|
|
Object.defineProperty(t, n.key, n);
|
|
}
|
|
}
|
|
function o(t, e, i) {
|
|
if (e) n(t.prototype, e);
|
|
if (i) n(t, i);
|
|
return t;
|
|
}
|
|
function a() {
|
|
return (
|
|
(a =
|
|
Object.assign ||
|
|
function (t) {
|
|
for (var e = 1; e < arguments.length; e++) {
|
|
var n = arguments[e];
|
|
for (var i in n)
|
|
if (Object.prototype.hasOwnProperty.call(n, i)) t[i] = n[i];
|
|
}
|
|
return t;
|
|
}),
|
|
a.apply(this, arguments)
|
|
);
|
|
}
|
|
var s = e(t),
|
|
u = e(Util),
|
|
l = "u-carousel",
|
|
f = "4.6.0",
|
|
c = "bs.u-carousel",
|
|
h = "bs.u-carousel.swipe",
|
|
p = "." + c,
|
|
m = ".data-u-api",
|
|
v = s["default"].fn[l],
|
|
g = 37,
|
|
y = 39,
|
|
w = 500,
|
|
b = 40,
|
|
Default = {
|
|
interval: 5e3,
|
|
keyboard: true,
|
|
slide: false,
|
|
pause: "hover",
|
|
wrap: true,
|
|
touch: false,
|
|
swipe: true,
|
|
},
|
|
C = {
|
|
interval: "(number|boolean)",
|
|
keyboard: "boolean",
|
|
slide: "(boolean|string)",
|
|
pause: "(string|boolean)",
|
|
wrap: "boolean",
|
|
touch: "boolean",
|
|
swipe: "boolean",
|
|
},
|
|
x = "next",
|
|
S = "prev",
|
|
A = "left",
|
|
_ = "right",
|
|
T = "u-slide" + p,
|
|
I = "slid" + p,
|
|
E = "keydown" + p,
|
|
k = "mouseenter" + p,
|
|
M = "mouseleave" + p,
|
|
L = "touchstart" + p,
|
|
B = "touchmove" + p,
|
|
O = "touchend" + p,
|
|
P = "pointerdown" + p,
|
|
F = "pointerup" + p,
|
|
N = "dragstart" + p,
|
|
z = "load" + p + m,
|
|
U = "click" + p + m,
|
|
H = "u-carousel",
|
|
$ = "u-active",
|
|
V = "u-slide",
|
|
Y = "u-carousel-item-right",
|
|
W = "u-carousel-item-left",
|
|
j = "u-carousel-item-next",
|
|
G = "u-carousel-item-prev",
|
|
Z = "pointer-event",
|
|
X = ".u-active",
|
|
K = ".u-active.u-carousel-item",
|
|
J = ".u-carousel-item",
|
|
tt = ".u-carousel-item img",
|
|
nt = ".u-carousel-item-next, .u-carousel-item-prev",
|
|
rt = ".u-carousel-indicators, .u-carousel-thumbnails",
|
|
ot = "[data-u-slide], [data-u-slide-to]",
|
|
at = '[data-u-ride="carousel"]',
|
|
st = { TOUCH: "touch", PEN: "pen" },
|
|
Carousel = (function () {
|
|
function Carousel(t, e) {
|
|
var n =
|
|
"ontouchstart" in document.documentElement ||
|
|
navigator.maxTouchPoints > 0;
|
|
(this._items = null),
|
|
(this._interval = null),
|
|
(this._activeElement = null),
|
|
(this._isPaused = false),
|
|
(this._isSliding = false),
|
|
(this.touchTimeout = null),
|
|
(this.touchStartX = 0),
|
|
(this.touchDeltaX = 0),
|
|
(this._config = this._getConfig(e)),
|
|
(this._element = t),
|
|
(this._indicatorsElement = this._element.querySelector(rt)),
|
|
(this._touchSupported = !this._element.matches(".u-form") && n),
|
|
(this._pointerEvent = Boolean(
|
|
window.PointerEvent || window.MSPointerEvent
|
|
)),
|
|
this._addEventListeners();
|
|
}
|
|
var e = Carousel.prototype;
|
|
return (
|
|
(e.next = function t() {
|
|
if (!this._isSliding) this._slide(x);
|
|
}),
|
|
(e.nextWhenVisible = function t() {
|
|
var e = s["default"](this._element);
|
|
if (
|
|
!document.hidden &&
|
|
e.is(":visible") &&
|
|
"hidden" !== e.css("visibility")
|
|
)
|
|
this.next();
|
|
}),
|
|
(e.prev = function t() {
|
|
if (!this._isSliding) this._slide(S);
|
|
}),
|
|
(e.pause = function t(e) {
|
|
if (!e) this._isPaused = true;
|
|
if (this._element.querySelector(nt))
|
|
u["default"].triggerTransitionEnd(this._element),
|
|
this.cycle(true);
|
|
clearInterval(this._interval), (this._interval = null);
|
|
}),
|
|
(e.cycle = function t(e) {
|
|
if (!e) this._isPaused = false;
|
|
if (this._interval)
|
|
clearInterval(this._interval), (this._interval = null);
|
|
if (this._config.interval && !this._isPaused)
|
|
this._updateInterval(),
|
|
(this._interval = setInterval(
|
|
(document.visibilityState
|
|
? this.nextWhenVisible
|
|
: this.next
|
|
).bind(this),
|
|
this._config.interval
|
|
));
|
|
}),
|
|
(e.to = function t(index) {
|
|
var e = this;
|
|
this._activeElement = this._element.querySelector(K);
|
|
var n = this._getItemIndex(this._activeElement);
|
|
if (!(index > this._items.length - 1 || index < 0)) {
|
|
if (this._isSliding)
|
|
return (
|
|
s["default"](this._element).one(I, function () {
|
|
return e.to(index);
|
|
}),
|
|
void 0
|
|
);
|
|
if (n === index) return this.pause(), this.cycle(), void 0;
|
|
var i = index > n ? x : S;
|
|
this._slide(i, this._items[index]);
|
|
}
|
|
}),
|
|
(e.dispose = function t() {
|
|
if (
|
|
(s["default"](this._element).off(p),
|
|
s["default"].removeData(this._element, c),
|
|
s["default"].removeData(this._element, h),
|
|
(this._items = null),
|
|
(this._config = null),
|
|
(this._element = null),
|
|
this._interval)
|
|
)
|
|
clearInterval(this._interval);
|
|
(this._interval = null),
|
|
(this._isPaused = null),
|
|
(this._isSliding = null),
|
|
(this._activeElement = null),
|
|
(this._indicatorsElement = null);
|
|
}),
|
|
(e._getConfig = function t(e) {
|
|
return (
|
|
(e = a({}, Default, e)),
|
|
u["default"].typeCheckConfig(l, e, C),
|
|
e
|
|
);
|
|
}),
|
|
(e._handleSwipe = function t() {
|
|
var e = Math.abs(this.touchDeltaX);
|
|
if (!(e <= b)) {
|
|
var n = e / this.touchDeltaX;
|
|
if (((this.touchDeltaX = 0), n > 0)) this.prev();
|
|
if (n < 0) this.next();
|
|
}
|
|
}),
|
|
(e._addEventListeners = function t() {
|
|
var e = this;
|
|
if (this._config.keyboard)
|
|
s["default"](this._element).on(E, function (t) {
|
|
return e._keydown(t);
|
|
});
|
|
if ("hover" === this._config.pause)
|
|
s["default"](this._element)
|
|
.on(k, function (t) {
|
|
return e.pause(t);
|
|
})
|
|
.on(M, function (t) {
|
|
return e.cycle(t);
|
|
});
|
|
if (this._config.touch) this._addTouchEventListeners();
|
|
}),
|
|
(e._addTouchEventListeners = function t() {
|
|
var e = this;
|
|
if (this._touchSupported) {
|
|
var n = function t(n) {
|
|
if (
|
|
e._pointerEvent &&
|
|
st[n.originalEvent.pointerType.toUpperCase()]
|
|
)
|
|
e.touchStartX = n.originalEvent.clientX;
|
|
else if (!e._pointerEvent)
|
|
e.touchStartX = n.originalEvent.touches[0].clientX;
|
|
},
|
|
move = function move(t) {
|
|
if (
|
|
t.originalEvent.touches &&
|
|
t.originalEvent.touches.length > 1
|
|
)
|
|
e.touchDeltaX = 0;
|
|
else
|
|
e.touchDeltaX =
|
|
t.originalEvent.touches[0].clientX - e.touchStartX;
|
|
},
|
|
i = function t(n) {
|
|
if (
|
|
e._pointerEvent &&
|
|
st[n.originalEvent.pointerType.toUpperCase()]
|
|
)
|
|
e.touchDeltaX = n.originalEvent.clientX - e.touchStartX;
|
|
if ((e._handleSwipe(), "hover" === e._config.pause)) {
|
|
if ((e.pause(), e.touchTimeout))
|
|
clearTimeout(e.touchTimeout);
|
|
e.touchTimeout = setTimeout(function (t) {
|
|
return e.cycle(t);
|
|
}, w + e._config.interval);
|
|
}
|
|
};
|
|
if (
|
|
(s["default"](this._element.querySelectorAll(tt)).on(
|
|
N,
|
|
function (t) {
|
|
return t.preventDefault();
|
|
}
|
|
),
|
|
this._pointerEvent)
|
|
)
|
|
s["default"](this._element).on(P, function (t) {
|
|
return n(t);
|
|
}),
|
|
s["default"](this._element).on(F, function (t) {
|
|
return i(t);
|
|
}),
|
|
this._element.classList.add(Z);
|
|
else
|
|
s["default"](this._element).on(L, function (t) {
|
|
return n(t);
|
|
}),
|
|
s["default"](this._element).on(B, function (t) {
|
|
return move(t);
|
|
}),
|
|
s["default"](this._element).on(O, function (t) {
|
|
return i(t);
|
|
});
|
|
}
|
|
}),
|
|
(e._keydown = function t(e) {
|
|
if (!/input|textarea/i.test(e.target.tagName))
|
|
switch (e.which) {
|
|
case g:
|
|
e.preventDefault(), this.prev();
|
|
break;
|
|
case y:
|
|
e.preventDefault(), this.next();
|
|
break;
|
|
}
|
|
}),
|
|
(e._getItemIndex = function t(e) {
|
|
return (
|
|
(this._items =
|
|
e && e.parentNode
|
|
? [].slice.call(e.parentNode.querySelectorAll(J))
|
|
: []),
|
|
this._items.indexOf(e)
|
|
);
|
|
}),
|
|
(e._getItemByDirection = function t(e, n) {
|
|
var i = e === x,
|
|
o = e === S,
|
|
a = this._getItemIndex(n),
|
|
s = this._items.length - 1,
|
|
u;
|
|
if (((o && 0 === a) || (i && a === s)) && !this._config.wrap)
|
|
return n;
|
|
var l,
|
|
f = (a + (e === S ? -1 : 1)) % this._items.length;
|
|
return -1 === f
|
|
? this._items[this._items.length - 1]
|
|
: this._items[f];
|
|
}),
|
|
(e._triggerSlideEvent = function t(e, n) {
|
|
var i = this._getItemIndex(e),
|
|
o = this._getItemIndex(this._element.querySelector(K)),
|
|
a = s["default"].Event(T, {
|
|
relatedTarget: e,
|
|
direction: n,
|
|
from: o,
|
|
to: i,
|
|
});
|
|
return s["default"](this._element).trigger(a), a;
|
|
}),
|
|
(e._setActiveIndicatorElement = function t(e) {
|
|
if (this._indicatorsElement) {
|
|
var n = [].slice.call(
|
|
this._indicatorsElement.querySelectorAll(X)
|
|
);
|
|
s["default"](n).removeClass($);
|
|
var i =
|
|
this._indicatorsElement.children[this._getItemIndex(e)];
|
|
if (i) s["default"](i).addClass($);
|
|
}
|
|
}),
|
|
(e._updateInterval = function t() {
|
|
var e = this._activeElement || this._element.querySelector(K);
|
|
if (e) {
|
|
var n = parseInt(e.getAttribute("data-interval"), 10);
|
|
if (n)
|
|
(this._config.defaultInterval =
|
|
this._config.defaultInterval || this._config.interval),
|
|
(this._config.interval = n);
|
|
else
|
|
this._config.interval =
|
|
this._config.defaultInterval || this._config.interval;
|
|
}
|
|
}),
|
|
(e._slide = function e(n, i) {
|
|
var o = this,
|
|
a = this._element.querySelector(K),
|
|
l = this._getItemIndex(a),
|
|
f = i || (a && this._getItemByDirection(n, a)),
|
|
c = this._getItemIndex(f),
|
|
h = Boolean(this._interval),
|
|
p,
|
|
m,
|
|
v,
|
|
g;
|
|
if (n === x) (p = W), (m = j), (v = A);
|
|
else (p = Y), (m = G), (v = _);
|
|
if (f && s["default"](f).hasClass($))
|
|
return (this._isSliding = false), void 0;
|
|
if (!this._triggerSlideEvent(f, v).isDefaultPrevented())
|
|
if (a && f) {
|
|
if (((this._isSliding = true), h)) this.pause();
|
|
this._setActiveIndicatorElement(f),
|
|
(this._activeElement = f);
|
|
var y = s["default"].Event(I, {
|
|
relatedTarget: f,
|
|
direction: v,
|
|
from: l,
|
|
to: c,
|
|
}),
|
|
w = null;
|
|
if (s["default"](this._element).hasClass(H)) {
|
|
s["default"](f).addClass(m),
|
|
u["default"].reflow(f),
|
|
s["default"](a).addClass(p),
|
|
s["default"](f).addClass(p);
|
|
var b = u["default"].getTransitionDurationFromElement(a),
|
|
C = this._element.className,
|
|
S = /u-carousel-duration-(\d+)/.exec(C);
|
|
if (S && 2 === S.length) b = parseFloat(S[1]) || 0;
|
|
if (h) {
|
|
var T =
|
|
parseFloat(t(this._element).attr("data-interval")) +
|
|
b;
|
|
if (Number.isFinite(T) && T > 0)
|
|
(w = this._config.interval),
|
|
(this._config.interval = T);
|
|
}
|
|
s["default"](a)
|
|
.one(u["default"].TRANSITION_END, function () {
|
|
s["default"](f)
|
|
.removeClass(p + " " + m)
|
|
.addClass($),
|
|
s["default"](a).removeClass($ + " " + m + " " + p),
|
|
(o._isSliding = false),
|
|
setTimeout(function () {
|
|
return s["default"](o._element).trigger(y);
|
|
}, 0);
|
|
})
|
|
.emulateTransitionEnd(b);
|
|
} else
|
|
s["default"](a).removeClass($),
|
|
s["default"](f).addClass($),
|
|
(this._isSliding = false),
|
|
s["default"](this._element).trigger(y);
|
|
if (h) this.cycle();
|
|
if (w) this._config.interval = w;
|
|
}
|
|
}),
|
|
(Carousel._jQueryInterface = function t(e) {
|
|
return this.each(function () {
|
|
var data = s["default"](this).data(c),
|
|
t = a({}, Default, s["default"](this).data());
|
|
if ("object" == typeof e) t = a({}, t, e);
|
|
var n = "string" == typeof e ? e : t.uSlide;
|
|
if (!data) {
|
|
var o;
|
|
if (
|
|
((data = new Carousel(this, t)),
|
|
s["default"](this).data(c, data),
|
|
!s["default"](this).data(h))
|
|
)
|
|
s["default"](this).data(h, new i(this, t));
|
|
}
|
|
if ("number" == typeof e) data.to(e);
|
|
else if ("string" == typeof n) {
|
|
if (void 0 === data[n])
|
|
throw new TypeError('No method named "' + n + '"');
|
|
data[n]();
|
|
} else if (t.interval && t.uRide) data.pause(), data.cycle();
|
|
});
|
|
}),
|
|
(Carousel._dataApiClickHandler = function t(e) {
|
|
var selector = u["default"].getSelectorFromElement(this);
|
|
if (selector) {
|
|
var n = s["default"](selector)[0];
|
|
if (n && s["default"](n).hasClass(H)) {
|
|
var i = a(
|
|
{},
|
|
s["default"](n).data(),
|
|
s["default"](this).data()
|
|
),
|
|
o = this.getAttribute("data-u-slide-to");
|
|
if (o) i.interval = false;
|
|
if ((Carousel._jQueryInterface.call(s["default"](n), i), o))
|
|
s["default"](n).data(c).to(o);
|
|
e.preventDefault();
|
|
}
|
|
}
|
|
}),
|
|
o(Carousel, null, [
|
|
{
|
|
key: "VERSION",
|
|
get: function t() {
|
|
return f;
|
|
},
|
|
},
|
|
{
|
|
key: "Default",
|
|
get: function t() {
|
|
return Default;
|
|
},
|
|
},
|
|
]),
|
|
Carousel
|
|
);
|
|
})();
|
|
return (
|
|
s["default"](document).on(U, ot, Carousel._dataApiClickHandler),
|
|
s["default"](window).on(z, function () {
|
|
for (
|
|
var t = [].slice.call(document.querySelectorAll(at)),
|
|
e = 0,
|
|
n = t.length;
|
|
e < n;
|
|
e++
|
|
) {
|
|
var i = s["default"](t[e]);
|
|
Carousel._jQueryInterface.call(i, i.data());
|
|
}
|
|
}),
|
|
(s["default"].fn[l] = Carousel._jQueryInterface),
|
|
(s["default"].fn[l].Constructor = Carousel),
|
|
(s["default"].fn[l].noConflict = function () {
|
|
return (s["default"].fn[l] = v), Carousel._jQueryInterface;
|
|
}),
|
|
Carousel
|
|
);
|
|
})($, bootstrap.Util)),
|
|
(window.bootstrap = bootstrap);
|
|
},
|
|
674: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
if (
|
|
((this.$element = o(t)),
|
|
(this.carousel = this.$element.data("bs.u-carousel")),
|
|
(this.options = o.extend({}, i.DEFAULTS, this.carousel._config)),
|
|
(this.startX = null),
|
|
(this.startY = null),
|
|
(this.startTime = null),
|
|
(this.cycling = null),
|
|
(this.$active = null),
|
|
(this.$items = null),
|
|
(this.$next = null),
|
|
(this.$prev = null),
|
|
(this.dx = null),
|
|
(this.sliding = false),
|
|
!this.$element.hasClass("u-form"))
|
|
)
|
|
this.$element
|
|
.on("touchstart.bs.u-carousel", this.touchstart.bind(this))
|
|
.on("touchmove.bs.u-carousel", this.touchmove.bind(this))
|
|
.on("touchend.bs.u-carousel", this.touchend.bind(this))
|
|
.on("u-slide.bs.u-carousel", this.startSliding.bind(this))
|
|
.on("slid.bs.u-carousel", this.stopSliding.bind(this));
|
|
}
|
|
t.exports = i;
|
|
var o = n(10);
|
|
(i.DEFAULTS = { swipe: 50 }),
|
|
(i.prototype.startSliding = function () {
|
|
this.sliding = true;
|
|
}),
|
|
(i.prototype.stopSliding = function () {
|
|
this.sliding = false;
|
|
}),
|
|
(i.prototype.touchstart = function (t) {
|
|
if (!this.sliding && this.options.swipe) {
|
|
var e = t.originalEvent.touches ? t.originalEvent.touches[0] : t;
|
|
(this.dx = 0),
|
|
(this.startX = e.pageX),
|
|
(this.startY = e.pageY),
|
|
(this.cycling = null),
|
|
(this.width = this.$element.width()),
|
|
(this.startTime = t.timeStamp);
|
|
}
|
|
}),
|
|
(i.prototype.touchmove = function (t) {
|
|
if (!this.sliding && this.options.swipe && this.startTime) {
|
|
var e = t.originalEvent.touches ? t.originalEvent.touches[0] : t,
|
|
n = e.pageX - this.startX,
|
|
i = e.pageY - this.startY;
|
|
if (!(Math.abs(n) < Math.abs(i))) {
|
|
if (null === this.cycling)
|
|
if (((this.cycling = !!this.carousel.interval), this.cycling))
|
|
this.carousel.pause();
|
|
t.preventDefault(),
|
|
(this.dx = (n / (this.width || 1)) * 100),
|
|
this.swipe(this.dx);
|
|
}
|
|
}
|
|
}),
|
|
(i.prototype.touchend = function (t) {
|
|
if (!this.sliding && this.options.swipe && this.startTime)
|
|
if (this.$active) {
|
|
var all = o()
|
|
.add(this.$active)
|
|
.add(this.$prev)
|
|
.add(this.$next)
|
|
.carousel_transition(true),
|
|
e = (t.timeStamp - this.startTime) / 1e3,
|
|
n = Math.abs(this.dx / e);
|
|
if (this.dx > 40 || (this.dx > 0 && n > this.options.swipe))
|
|
this.carousel.prev();
|
|
else if (this.dx < -40 || (this.dx < 0 && n > this.options.swipe))
|
|
this.carousel.next();
|
|
else
|
|
this.$active
|
|
.one(o.support.transition.end, function () {
|
|
all.removeClass("u-carousel-item-prev u-carousel-item-next");
|
|
})
|
|
.emulateTransitionEnd(
|
|
1e3 * this.$active.css("transition-duration").slice(0, -1)
|
|
);
|
|
if ((all.css("transform", ""), this.cycling)) this.carousel.cycle();
|
|
(this.$active = null), (this.startTime = null);
|
|
}
|
|
}),
|
|
(i.prototype.swipe = function (t) {
|
|
var e = this.$active || this.getActive();
|
|
if (t < 0) {
|
|
if (
|
|
(this.$prev
|
|
.css("transform", "translate3d(0,0,0)")
|
|
.removeClass("u-carousel-item-prev")
|
|
.carousel_transition(true),
|
|
!this.$next.length || this.$next.hasClass("u-active"))
|
|
)
|
|
return;
|
|
this.$next
|
|
.carousel_transition(false)
|
|
.addClass("u-carousel-item-next")
|
|
.css("transform", "translate3d(" + (t + 100) + "%,0,0)");
|
|
} else {
|
|
if (
|
|
(this.$next
|
|
.css("transform", "")
|
|
.removeClass("u-carousel-item-next")
|
|
.carousel_transition(true),
|
|
!this.$prev.length || this.$prev.hasClass("u-active"))
|
|
)
|
|
return;
|
|
this.$prev
|
|
.carousel_transition(false)
|
|
.addClass("u-carousel-item-prev")
|
|
.css("transform", "translate3d(" + (t - 100) + "%,0,0)");
|
|
}
|
|
e.carousel_transition(false).css(
|
|
"transform",
|
|
"translate3d(" + t + "%, 0, 0)"
|
|
);
|
|
}),
|
|
(i.prototype.getActive = function () {
|
|
if (
|
|
((this.$active = this.$element.find(".u-carousel-item.u-active")),
|
|
(this.$items = this.$active.parent().children()),
|
|
(this.$next = this.$active.next()),
|
|
!this.$next.length && this.options.wrap)
|
|
)
|
|
this.$next = this.$items.first();
|
|
if (
|
|
((this.$prev = this.$active.prev()),
|
|
!this.$prev.length && this.options.wrap)
|
|
)
|
|
this.$prev = this.$items.last();
|
|
return this.$active;
|
|
}),
|
|
(o.fn.carousel_transition = function (t) {
|
|
return (
|
|
(t = t ? "" : "none"),
|
|
this.each(function () {
|
|
o(this).css("transition", t);
|
|
})
|
|
);
|
|
});
|
|
},
|
|
691: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
var data = t.attr("data-map");
|
|
if (data) {
|
|
data = Utility.decodeJsonAttribute(data);
|
|
var e = t.contents()[0],
|
|
n = e.createElement("script");
|
|
(n.type = "text/javascript"),
|
|
(n.innerHTML =
|
|
"var data = " +
|
|
JSON.stringify(data) +
|
|
";\n;" +
|
|
"var mapIframeApiReady = function () {\n" +
|
|
' parent.mapIframeApiReady(google, document.getElementById("map"), data);\n' +
|
|
"}");
|
|
var i = e.createElement("script");
|
|
if (
|
|
((i.type = "text/javascript"),
|
|
(i.src =
|
|
"//maps.google.com/maps/api/js?key=" +
|
|
data.apiKey +
|
|
"&callback=mapIframeApiReady"),
|
|
data.lang)
|
|
)
|
|
i.src += "&language=" + data.lang;
|
|
e.head.appendChild(n),
|
|
e.head.appendChild(i),
|
|
$(e.body).append(
|
|
"<style>" +
|
|
" #map { width: 100%; height: 100%; }" +
|
|
" body { margin: 0; }" +
|
|
" .marker-internal { width: 180px; font-weight: normal; }" +
|
|
" .marker-internal a { text-decoration: none; color:#427fed; }" +
|
|
" .marker-internal strong { font-weight: 500; font-size: 14px; }" +
|
|
"</style>" +
|
|
'<div id="map"></div>'
|
|
);
|
|
}
|
|
}
|
|
function o(t) {
|
|
var e = "";
|
|
if (t.title) e += "<strong>" + t.title + "</strong>";
|
|
if (t.description)
|
|
e += "<div>" + t.description.replace(/\n/g, "<br>") + "</div>";
|
|
if (t.linkUrl) {
|
|
var url, n;
|
|
e +=
|
|
'<a href="' +
|
|
t.linkUrl +
|
|
'" target="_blank"><span>' +
|
|
(t.linkCaption || t.linkUrl) +
|
|
"</span></a>";
|
|
}
|
|
if (e) e = '<div class="marker-internal">' + e + "</div>";
|
|
return e;
|
|
}
|
|
var MapsLoader = {};
|
|
(window.loadMapsContent = function () {
|
|
$("iframe.map-content").each(function () {
|
|
var t = $(this);
|
|
if (0 === t.contents().find("#map").length) i(t);
|
|
});
|
|
}),
|
|
(window.mapIframeApiReady = function (google, t, data) {
|
|
data.markers = data.markers || [];
|
|
var e = data.zoom;
|
|
if (!e && 1 === data.markers.length) e = data.markers[0].zoom;
|
|
if (!e) e = 14;
|
|
if (
|
|
((e = parseInt(e, 10)),
|
|
(data.map = data.map || {}),
|
|
(data.map.zoom = e),
|
|
(data.map.mapTypeId =
|
|
"satellite" === data.typeId
|
|
? google.maps.MapTypeId.HYBRID
|
|
: google.maps.MapTypeId.ROADMAP),
|
|
data.markers.length)
|
|
)
|
|
data.map.center = data.markers[0].position;
|
|
var map = new google.maps.Map(t, data.map || {}),
|
|
n = new google.maps.LatLngBounds();
|
|
if (
|
|
(data.markers.forEach(function (t) {
|
|
t.map = map;
|
|
var e = new google.maps.Marker(t);
|
|
n.extend(new google.maps.LatLng(t.position.lat, t.position.lng));
|
|
var i = o(t);
|
|
if (i) {
|
|
var a = new google.maps.InfoWindow({
|
|
content: $("<textarea/>").html(i).text(),
|
|
});
|
|
e.addListener("click", function () {
|
|
a.open(e.get("map"), e);
|
|
});
|
|
}
|
|
}),
|
|
data.markers.length > 1 && e && !isNaN(e))
|
|
) {
|
|
map.fitBounds(n);
|
|
var i = google.maps.event.addListener(
|
|
map,
|
|
"zoom_changed",
|
|
function () {
|
|
if (
|
|
(google.maps.event.removeListener(i),
|
|
map.getZoom() > e || 0 === map.getZoom())
|
|
)
|
|
map.setZoom(e);
|
|
}
|
|
);
|
|
}
|
|
}),
|
|
(window.MapsLoader = MapsLoader);
|
|
},
|
|
692: function (t, e, n) {
|
|
"use strict";
|
|
function ResponsiveMenu(t, e) {
|
|
(this.responsive = t), (this.root = e || i("body")), this.init();
|
|
}
|
|
t.exports = ResponsiveMenu;
|
|
var i = window.jQuery;
|
|
(ResponsiveMenu.prototype.init = function init() {
|
|
if (this.root.is("body")) this.subscribe();
|
|
this.initStyles();
|
|
}),
|
|
(ResponsiveMenu.prototype.subscribe = function t() {
|
|
this.root.on(
|
|
"click",
|
|
".u-menu .menu-collapse",
|
|
function (t) {
|
|
t.preventDefault();
|
|
var e = i(t.currentTarget).closest(".u-menu");
|
|
if (ResponsiveMenu.isActive(e)) this.close(e);
|
|
else this.open(e);
|
|
}.bind(this)
|
|
),
|
|
this.root.on(
|
|
"click",
|
|
".u-menu .u-menu-close",
|
|
function (t) {
|
|
t.preventDefault();
|
|
var e = i(t.currentTarget).closest(".u-menu");
|
|
this.close(e);
|
|
}.bind(this)
|
|
),
|
|
this.root.on(
|
|
"click",
|
|
".u-menu .u-menu-overlay",
|
|
function (t) {
|
|
var e = i(t.currentTarget).closest(".u-menu.open");
|
|
this.close(e);
|
|
}.bind(this)
|
|
),
|
|
this.root.find(".u-menu").on(
|
|
"click",
|
|
".u-nav-container-collapse .u-nav-link",
|
|
function (t) {
|
|
var e = i(t.currentTarget),
|
|
n;
|
|
if (!e.siblings(".u-nav-popup").length) {
|
|
var o = e.attr("href");
|
|
if (o && -1 !== o.indexOf("#")) {
|
|
var a = i(t.currentTarget).closest(".u-menu");
|
|
this.close(a);
|
|
}
|
|
}
|
|
}.bind(this)
|
|
),
|
|
this.root
|
|
.find(".u-menu:not(.u-menu-one-level)")
|
|
.on("click", ".u-nav-container-collapse .u-nav-link", function (t) {
|
|
var e = i(t.currentTarget).siblings(".u-nav-popup"),
|
|
nav,
|
|
n =
|
|
e.closest(".u-menu").attr("data-submenu-level") || "on-click";
|
|
if (e.length && "on-click" === n) {
|
|
t.preventDefault(),
|
|
t.stopPropagation(),
|
|
(t.returnValue = false),
|
|
e.one(
|
|
"transitionend webkitTransitionEnd oTransitionEnd",
|
|
function (t) {
|
|
t.stopPropagation(),
|
|
e.removeClass("animating"),
|
|
e.toggleClass("open"),
|
|
e.css({
|
|
"max-height": e.is(".open") ? "none" : "",
|
|
visibility: "",
|
|
}),
|
|
e
|
|
.find(".open")
|
|
.removeClass("open")
|
|
.css("max-height", "");
|
|
}
|
|
),
|
|
e.css({ "max-height": "none", visibility: "visible" });
|
|
var o = e.outerHeight();
|
|
e.css("max-height", e.is(".open") ? o : 0),
|
|
e.addClass("animating"),
|
|
e[0].offsetHeight,
|
|
e.css("max-height", e.is(".open") ? 0 : o);
|
|
}
|
|
}),
|
|
i(window).on(
|
|
"resize",
|
|
function () {
|
|
if (this.screenWidth !== window.innerWidth)
|
|
i(".u-menu.open").each(
|
|
function (t, el) {
|
|
this.close(i(el));
|
|
}.bind(this)
|
|
);
|
|
}.bind(this)
|
|
),
|
|
i(document).keyup(
|
|
function (t) {
|
|
if (27 === t.keyCode)
|
|
i(".u-menu.open").each(
|
|
function (t, el) {
|
|
this.close(i(el));
|
|
}.bind(this)
|
|
);
|
|
}.bind(this)
|
|
),
|
|
i(this.root).on(
|
|
"mouseenter touchstart",
|
|
".u-nav-container ul > li",
|
|
function (t) {
|
|
ResponsiveMenu.fixDirection(this.root, i(t.currentTarget));
|
|
}.bind(this)
|
|
);
|
|
}),
|
|
(ResponsiveMenu.prototype.initStyles = function t() {
|
|
this.root.find(".u-menu").each(function () {
|
|
var menu = i(this),
|
|
style = menu.find(".offcanvas-style"),
|
|
t =
|
|
menu
|
|
.find(".u-nav-container-collapse .u-sidenav")
|
|
.attr("data-offcanvas-width") || 250;
|
|
if (!style.length)
|
|
(style = i('<style class="offcanvas-style"></style>')),
|
|
menu.append(style);
|
|
style.html(
|
|
" .u-offcanvas .u-sidenav { flex-basis: {width} !important; } .u-offcanvas:not(.u-menu-open-right) .u-sidenav { margin-left: -{width}; } .u-offcanvas.u-menu-open-right .u-sidenav { margin-right: -{width}; } @keyframes menu-shift-left { from { left: 0; } to { left: {width}; } } @keyframes menu-unshift-left { from { left: {width}; } to { left: 0; } } @keyframes menu-shift-right { from { right: 0; } to { right: {width}; } } @keyframes menu-unshift-right { from { right: {width}; } to { right: 0; } } ".replace(
|
|
/\{width\}/g,
|
|
t + "px"
|
|
)
|
|
);
|
|
});
|
|
}),
|
|
(ResponsiveMenu.prototype.onResponsiveResize = function t() {
|
|
i(".u-menu").each(
|
|
function (t, el) {
|
|
var e = i(el).attr("data-responsive-from") || "MD",
|
|
n = this.responsive.modes.indexOf(e),
|
|
o = this.responsive.modes.slice(n);
|
|
ResponsiveMenu.toggleResponsive(
|
|
el,
|
|
-1 !== o.indexOf(this.responsive.mode)
|
|
),
|
|
this.megaResize(el, 1);
|
|
}.bind(this)
|
|
);
|
|
}),
|
|
(ResponsiveMenu.toggleResponsive = function t(e, n) {
|
|
i(e).toggleClass("u-enable-responsive", n);
|
|
}),
|
|
(ResponsiveMenu.prototype.close = function close(menu, t) {
|
|
if (!window.app || !window.app.modes) {
|
|
if (ResponsiveMenu.isActive(menu)) this.closeMenu(menu, t);
|
|
} else if (
|
|
(this.closeMenu(menu, t),
|
|
this.setOverlayOpacity(menu),
|
|
ResponsiveMenu.isOffcanvasMode(menu))
|
|
)
|
|
app.modes().resetOffCanvas();
|
|
}),
|
|
(ResponsiveMenu.prototype.closeMenu = function t(menu, e) {
|
|
if ((this.enableScroll(), ResponsiveMenu.isOffcanvasMode(menu)))
|
|
this.offcanvasMenuClose(menu);
|
|
else this.overlayMenuClose(menu);
|
|
this.root.removeClass("menu-overlay"), this.hideOverlay(menu, e);
|
|
}),
|
|
(ResponsiveMenu.prototype.open = function open(menu) {
|
|
if (
|
|
(this.root.addClass("menu-overlay"), !window.app || !window.app.modes)
|
|
) {
|
|
if (!ResponsiveMenu.isActive(menu)) this.openMenu(menu);
|
|
} else if (
|
|
(this.setOverlayOpacity(menu),
|
|
this.openMenu(menu),
|
|
ResponsiveMenu.isOffcanvasMode(menu))
|
|
)
|
|
app.modes().setOffCanvas();
|
|
}),
|
|
(ResponsiveMenu.prototype.setOverlayOpacity = function t(menu) {
|
|
menu.find(".u-menu-overlay").css("opacity", "");
|
|
}),
|
|
(ResponsiveMenu.prototype.openMenu = function open(menu) {
|
|
if (
|
|
((this.screenWidth = window.innerWidth),
|
|
this.disableScroll(),
|
|
ResponsiveMenu.isOffcanvasMode(menu))
|
|
)
|
|
this.offcanvasMenuOpen(menu);
|
|
else this.overlayMenuOpen(menu);
|
|
this.showOverlay(menu);
|
|
}),
|
|
(ResponsiveMenu.prototype.offcanvasMenuOpen = function t(menu) {
|
|
var e = this.root;
|
|
if (
|
|
(menu.addClass("open"),
|
|
e.addClass("u-offcanvas-opened"),
|
|
menu.is(".u-offcanvas-shift"))
|
|
)
|
|
e.addClass(
|
|
"u-offcanvas-shifted-" +
|
|
(menu.hasClass("u-menu-open-right") ? "right" : "left")
|
|
);
|
|
}),
|
|
(ResponsiveMenu.prototype.offcanvasMenuClose = function t(menu) {
|
|
if (
|
|
(menu.removeClass("open"),
|
|
this.root.removeClass(
|
|
"u-offcanvas-opened u-offcanvas-shifted-left u-offcanvas-shifted-right"
|
|
),
|
|
menu.is(".u-offcanvas-shift"))
|
|
)
|
|
this.root.addClass(
|
|
"u-offcanvas-unshifted-" +
|
|
(menu.hasClass("u-menu-open-right") ? "right" : "left")
|
|
);
|
|
}),
|
|
(ResponsiveMenu.prototype.megaResize = function t(menu, e) {
|
|
if (((menu = i(menu)), (e = e || 1), menu.hasClass("u-menu-mega")))
|
|
menu.outerHeight(),
|
|
menu.each(function () {
|
|
var menu = i(this);
|
|
menu.find(".u-mega-popup").each(function () {
|
|
var t = i(this),
|
|
n = t.attr("data-mega-width") || "content";
|
|
if ("custom" !== n && "content" !== n) {
|
|
var o =
|
|
"sheet" === n
|
|
? menu.closest(".u-sheet, .u-body")
|
|
: menu.closest("body, .u-body"),
|
|
a = o.offset(),
|
|
s = o.outerWidth();
|
|
if (
|
|
(t.css({ left: "", width: "" }),
|
|
t.removeClass("u-popup-left u-popup-right"),
|
|
t.addClass("u-hidden"),
|
|
menu.outerHeight(),
|
|
t.removeClass("u-hidden"),
|
|
menu.outerHeight(),
|
|
"content" === n)
|
|
)
|
|
return t.css("width", "auto"), void 0;
|
|
var u = t.offset(),
|
|
l = (a.left - u.left) / e,
|
|
f = parseFloat(t.css("left") || 0);
|
|
t.css({ left: f + Math.round(l) + "px", width: s + "px" });
|
|
}
|
|
});
|
|
});
|
|
}),
|
|
(ResponsiveMenu.prototype.hideOverlay = function t(menu, e) {
|
|
var overlay = menu.find(".u-menu-overlay"),
|
|
n = function () {
|
|
if (!ResponsiveMenu.isActive(menu))
|
|
menu.find(".u-nav-container-collapse").css("width", ""),
|
|
this.root.filter("body").find("header.u-sticky").css("top", "");
|
|
}.bind(this);
|
|
if (e) n();
|
|
else overlay.fadeOut(500, n);
|
|
}),
|
|
(ResponsiveMenu.prototype.showOverlay = function t(menu) {
|
|
var overlay = menu.find(".u-menu-overlay");
|
|
menu.find(".u-nav-container-collapse").css("width", "100%"),
|
|
overlay.fadeIn(500);
|
|
}),
|
|
(ResponsiveMenu.prototype.disableScroll = function t() {
|
|
if (this.root.is("body"))
|
|
document.documentElement.style.overflow = "hidden";
|
|
}),
|
|
(ResponsiveMenu.prototype.enableScroll = function t() {
|
|
if (this.root.is("body")) document.documentElement.style.overflow = "";
|
|
}),
|
|
(ResponsiveMenu.prototype.overlayMenuOpen = function t(menu) {
|
|
menu.addClass("open");
|
|
}),
|
|
(ResponsiveMenu.prototype.overlayMenuClose = function t(menu) {
|
|
menu.removeClass("open");
|
|
}),
|
|
(ResponsiveMenu.isOffcanvasMode = function (menu) {
|
|
return menu.is(".u-offcanvas");
|
|
}),
|
|
(ResponsiveMenu.isActive = function (menu) {
|
|
return menu.hasClass("open");
|
|
}),
|
|
(ResponsiveMenu.fixDirection = function t(e, el) {
|
|
if (el && el.length) {
|
|
e = i(e);
|
|
var n = "u-popup-left",
|
|
o = "u-popup-right",
|
|
a;
|
|
i(el)
|
|
.children(".u-nav-popup")
|
|
.each(function () {
|
|
var t = i(this);
|
|
t.removeClass(n + " " + o);
|
|
var a = t.parent().closest(".u-nav-popup"),
|
|
s = t.attr("data-mega-width") || "content",
|
|
u = Boolean(a.length);
|
|
if ("content" === s) {
|
|
var l = "";
|
|
if (t.parents("." + n).length) l = n;
|
|
else if (t.parents("." + o).length) l = o;
|
|
if (l) t.addClass(l);
|
|
else {
|
|
var f = t[0].getBoundingClientRect(),
|
|
c = e[0].getBoundingClientRect(),
|
|
h =
|
|
"undefined" == typeof app ? 1 : app.editor.preview.scale,
|
|
p = f.right - c.right,
|
|
m = c.left - f.left;
|
|
if (p > 1)
|
|
t.css("left", u ? "" : (c.right - f.right) / h + "px"),
|
|
t.css("right", u ? "" : "auto"),
|
|
t.addClass(n);
|
|
else if (m > 1)
|
|
t.css("left", u ? "" : "0px"),
|
|
t.css("right", u ? "" : "auto"),
|
|
t.addClass(o);
|
|
}
|
|
}
|
|
});
|
|
}
|
|
}),
|
|
(window.ResponsiveMenu = ResponsiveMenu);
|
|
},
|
|
8: function (t, e, n) {
|
|
"use strict";
|
|
t.exports = { options: { usePureJavaScript: false } };
|
|
},
|
|
86: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
throw new Error("setTimeout has not been defined");
|
|
}
|
|
function o() {
|
|
throw new Error("clearTimeout has not been defined");
|
|
}
|
|
function a(t) {
|
|
if (p === setTimeout) return setTimeout(t, 0);
|
|
if ((p === i || !p) && setTimeout)
|
|
return (p = setTimeout), setTimeout(t, 0);
|
|
try {
|
|
return p(t, 0);
|
|
} catch (e) {
|
|
try {
|
|
return p.call(null, t, 0);
|
|
} catch (e) {
|
|
return p.call(this, t, 0);
|
|
}
|
|
}
|
|
}
|
|
function s(t) {
|
|
if (m === clearTimeout) return clearTimeout(t);
|
|
if ((m === o || !m) && clearTimeout)
|
|
return (m = clearTimeout), clearTimeout(t);
|
|
try {
|
|
return m(t);
|
|
} catch (e) {
|
|
try {
|
|
return m.call(null, t);
|
|
} catch (e) {
|
|
return m.call(this, t);
|
|
}
|
|
}
|
|
}
|
|
function u() {
|
|
if (g && y) {
|
|
if (((g = false), y.length)) v = y.concat(v);
|
|
else w = -1;
|
|
if (v.length) l();
|
|
}
|
|
}
|
|
function l() {
|
|
if (!g) {
|
|
var t = a(u);
|
|
g = true;
|
|
for (var e = v.length; e;) {
|
|
for (y = v, v = []; ++w < e;) if (y) y[w].run();
|
|
(w = -1), (e = v.length);
|
|
}
|
|
(y = null), (g = false), s(t);
|
|
}
|
|
}
|
|
function f(t, e) {
|
|
(this.fun = t), (this.array = e);
|
|
}
|
|
function c() { }
|
|
var h = (t.exports = {}),
|
|
p,
|
|
m;
|
|
!(function () {
|
|
try {
|
|
if ("function" == typeof setTimeout) p = setTimeout;
|
|
else p = i;
|
|
} catch (t) {
|
|
p = i;
|
|
}
|
|
try {
|
|
if ("function" == typeof clearTimeout) m = clearTimeout;
|
|
else m = o;
|
|
} catch (t) {
|
|
m = o;
|
|
}
|
|
})();
|
|
var v = [],
|
|
g = false,
|
|
y,
|
|
w = -1;
|
|
(h.nextTick = function (t) {
|
|
var e = new Array(arguments.length - 1);
|
|
if (arguments.length > 1)
|
|
for (var n = 1; n < arguments.length; n++) e[n - 1] = arguments[n];
|
|
if ((v.push(new f(t, e)), 1 === v.length && !g)) a(l);
|
|
}),
|
|
(f.prototype.run = function () {
|
|
this.fun.apply(null, this.array);
|
|
}),
|
|
(h.title = "browser"),
|
|
(h.browser = true),
|
|
(h.env = {}),
|
|
(h.argv = []),
|
|
(h.version = ""),
|
|
(h.versions = {}),
|
|
(h.on = c),
|
|
(h.addListener = c),
|
|
(h.once = c),
|
|
(h.off = c),
|
|
(h.removeListener = c),
|
|
(h.removeAllListeners = c),
|
|
(h.emit = c),
|
|
(h.prependListener = c),
|
|
(h.prependOnceListener = c),
|
|
(h.listeners = function (t) {
|
|
return [];
|
|
}),
|
|
(h.binding = function (t) {
|
|
throw new Error("process.binding is not supported");
|
|
}),
|
|
(h.cwd = function () {
|
|
return "/";
|
|
}),
|
|
(h.chdir = function (t) {
|
|
throw new Error("process.chdir is not supported");
|
|
}),
|
|
(h.umask = function () {
|
|
return 0;
|
|
});
|
|
},
|
|
96: function (t, e, n) {
|
|
"use strict";
|
|
t.exports = {
|
|
IMAGES: "IMAGES",
|
|
DOCUMENTS: "DOCUMENTS",
|
|
VIDEO: "VIDEO",
|
|
AUDIO: "AUDIO",
|
|
CUSTOM: "CUSTOM",
|
|
};
|
|
},
|
|
9796: function (t, e, n) {
|
|
"use strict";
|
|
n(9797), n(9863);
|
|
},
|
|
9797: function (t, e, n) {
|
|
"use strict";
|
|
n(9798);
|
|
},
|
|
9798: function (t, e, n) {
|
|
"use strict";
|
|
n(9799),
|
|
n(9800),
|
|
n(363),
|
|
n(9801),
|
|
n(9802),
|
|
n(9805),
|
|
n(9806),
|
|
n(9807),
|
|
n(673),
|
|
n(691),
|
|
n(9808),
|
|
n(9816),
|
|
n(9817),
|
|
n(9819),
|
|
n(9821),
|
|
n(9822),
|
|
n(9823),
|
|
n(9824),
|
|
n(469),
|
|
n(9825),
|
|
n(9830),
|
|
n(9831),
|
|
n(9833),
|
|
n(9834),
|
|
n(9836),
|
|
n(9838),
|
|
n(9839),
|
|
n(9841),
|
|
n(9842),
|
|
n(9843),
|
|
n(9844),
|
|
n(9845),
|
|
n(9846),
|
|
n(9847),
|
|
n(9848),
|
|
n(9849),
|
|
n(9850),
|
|
n(9851),
|
|
n(9852),
|
|
n(9855),
|
|
n(9856),
|
|
n(9857),
|
|
n(9860),
|
|
n(9862);
|
|
},
|
|
9799: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
if (window && document && "complete" !== document.readyState) {
|
|
var t = document.body;
|
|
if (
|
|
t &&
|
|
t.classList &&
|
|
"function" == typeof t.classList.add &&
|
|
"function" == typeof t.classList.remove &&
|
|
"function" == typeof t.appendChild &&
|
|
"function" == typeof document.createElement &&
|
|
"function" == typeof window.addEventListener
|
|
) {
|
|
var e = "u-disable-duration";
|
|
t.classList.add(e);
|
|
var styleNode = document.createElement("style");
|
|
(styleNode.innerHTML =
|
|
".u-disable-duration * {transition-duration: 0s !important;}"),
|
|
t.appendChild(styleNode),
|
|
window.addEventListener("load", function () {
|
|
t.classList.remove(e);
|
|
});
|
|
}
|
|
}
|
|
}
|
|
i();
|
|
},
|
|
9800: function (t, e, n) {
|
|
"use strict";
|
|
if (!("CSS" in window)) window.CSS = {};
|
|
if (!("supports" in window.CSS))
|
|
"use strict",
|
|
(window.CSS._cacheSupports = {}),
|
|
(window.CSS.supports = function (t, e) {
|
|
function n(t, e) {
|
|
var style = document.createElement("div").style;
|
|
if (void 0 === e) {
|
|
var n = function (t, e) {
|
|
var n = t.split(e);
|
|
if (n.length > 1)
|
|
return n
|
|
.map(function (t, index, e) {
|
|
return index % 2 == 0 ? t + e[index + 1] : "";
|
|
})
|
|
.filter(Boolean);
|
|
},
|
|
i = n(t, /([)])\s*or\s*([(])/gi);
|
|
if (i)
|
|
return i.some(function (t) {
|
|
return window.CSS.supports(t);
|
|
});
|
|
var o = n(t, /([)])\s*and\s*([(])/gi);
|
|
if (o)
|
|
return o.every(function (t) {
|
|
return window.CSS.supports(t);
|
|
});
|
|
style.cssText = t.replace("(", "").replace(/[)]$/, "");
|
|
} else style.cssText = t + ":" + e;
|
|
return !!style.length;
|
|
}
|
|
var i = [t, e].toString();
|
|
if (i in window.CSS._cacheSupports)
|
|
return window.CSS._cacheSupports[i];
|
|
else return (window.CSS._cacheSupports[i] = n(t, e));
|
|
});
|
|
},
|
|
9801: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
if (
|
|
((this.prevMode = ""),
|
|
(this.resizeTimeout = 50),
|
|
(this.sheet = {
|
|
XS: 340,
|
|
SM: 540,
|
|
MD: 720,
|
|
LG: 940,
|
|
XL: 1140,
|
|
XXL: 1320,
|
|
}),
|
|
(this.mediaMax = { XS: 575, SM: 767, MD: 991, LG: 1199 }),
|
|
(this.modes = ["XL", "LG", "MD", "SM", "XS"]),
|
|
(this.defaultMode = "XL"),
|
|
document.body.classList.contains("u-xxl-mode"))
|
|
)
|
|
(this.mediaMax.XXL = 1399),
|
|
(this.defaultMode = "XXL"),
|
|
this.modes.splice(0, 0, "XXL");
|
|
(this._handlers = []),
|
|
this.modes.forEach(function (t) {
|
|
var e = document.body.style.getPropertyValue(
|
|
"--theme-sheet-width-" + t.toLowerCase()
|
|
);
|
|
if (((e = parseFloat(e)), Number.isFinite(e))) this.sheet[t] = e;
|
|
}),
|
|
this.init(t || []);
|
|
}
|
|
var ResponsiveMenu = n(692),
|
|
o = n(10);
|
|
Object.defineProperty(i.prototype, "mode", {
|
|
get: function () {
|
|
var t =
|
|
(document.documentElement || document.body).clientWidth ||
|
|
window.innerWidth;
|
|
if (this.scrolbar)
|
|
document.documentElement.setAttribute("style", "overflow-y:hidden"),
|
|
(t =
|
|
(document.documentElement || document.body).clientWidth ||
|
|
window.innerWidth),
|
|
document.documentElement.removeAttribute("style");
|
|
for (var e in this.mediaMax)
|
|
if (this.mediaMax.hasOwnProperty(e))
|
|
if (t <= this.mediaMax[e]) return e;
|
|
return this.defaultMode;
|
|
},
|
|
}),
|
|
(i.prototype.init = function init(t) {
|
|
o(
|
|
function () {
|
|
this.update(true),
|
|
(this.scrolbar = !!(
|
|
document.body &&
|
|
document.body.clientWidth !== document.body.scrollWidth
|
|
));
|
|
}.bind(this)
|
|
),
|
|
o(window).on(
|
|
"resize",
|
|
function () {
|
|
this.update(true);
|
|
}.bind(this)
|
|
),
|
|
t.forEach(function (t) {
|
|
this._handlers.push(new t(this));
|
|
}, this),
|
|
this.update();
|
|
}),
|
|
(i.prototype.update = function update(t) {
|
|
var e = function () {
|
|
if (
|
|
this.mode !== this.prevMode ||
|
|
this.getContentWidth() < this.sheet[this.mode]
|
|
)
|
|
this._handlers.forEach(function (t) {
|
|
if ("function" == typeof t.onResponsiveBefore)
|
|
t.onResponsiveBefore();
|
|
}),
|
|
this.responsiveClass(o("html")),
|
|
this._handlers.forEach(function (t) {
|
|
if ("function" == typeof t.onResponsiveAfter)
|
|
t.onResponsiveAfter();
|
|
}),
|
|
(this.prevMode = this.mode);
|
|
this._handlers.forEach(function (t) {
|
|
if ("function" == typeof t.onResponsiveResize)
|
|
t.onResponsiveResize();
|
|
});
|
|
}.bind(this);
|
|
if (t)
|
|
clearTimeout(this._timeoutId),
|
|
(this._timeoutId = setTimeout(e, this.resizeTimeout));
|
|
else e();
|
|
}),
|
|
(i.prototype.responsiveClass = function t(e) {
|
|
var removeList = Object.keys(this.sheet)
|
|
.map(function (t) {
|
|
return "u-responsive-" + t.toLowerCase();
|
|
})
|
|
.join(" ");
|
|
e.removeClass(removeList),
|
|
e.addClass("u-responsive-" + this.mode.toLowerCase());
|
|
}),
|
|
(i.prototype.getContentWidth = function () {
|
|
return o(".u-body section:first").parent().width();
|
|
}),
|
|
o(function () {
|
|
(window._responsive = new i([ResponsiveMenu])),
|
|
o(document).on(
|
|
"click",
|
|
"[data-href]:not(.u-back-to-top), [data-post-link]",
|
|
function (t) {
|
|
if (!t.isDefaultPrevented()) {
|
|
var e = o(this),
|
|
url = e.attr("data-href") || e.attr("data-post-link"),
|
|
n = e.attr("data-target") || "";
|
|
if (n) window.open(url, n);
|
|
else window.location.href = url;
|
|
}
|
|
}
|
|
);
|
|
});
|
|
},
|
|
9802: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
return {
|
|
submit: function (t) {
|
|
t.preventDefault(), t.stopPropagation();
|
|
var form = h(this);
|
|
form.find('input[type="submit"]').prop("disabled", true);
|
|
var url = form.attr("action"),
|
|
e = form.attr("source"),
|
|
n = form.attr("method") || "POST",
|
|
i = "";
|
|
if (
|
|
(c(form),
|
|
("email" === e || "customphp" === e) &&
|
|
"true" === form.attr("redirect"))
|
|
)
|
|
i =
|
|
form.attr("redirect-url") &&
|
|
!h.isNumeric(form.attr("redirect-url"))
|
|
? form.attr("redirect-url")
|
|
: form.attr("redirect-address");
|
|
if (
|
|
"email" === e &&
|
|
!h(form).find('input[name="npspec-referer"]').length
|
|
)
|
|
h(form).append(
|
|
'<input type="hidden" name="npspec-referer" value="' +
|
|
window.location.href +
|
|
'">'
|
|
);
|
|
var o = document.location && document.location.protocol,
|
|
u;
|
|
if (
|
|
navigator.userAgent &&
|
|
navigator.userAgent.match(/firefox|fxios/i) &&
|
|
"file:" === o
|
|
)
|
|
FormMessage.showError(
|
|
form,
|
|
"The page is opened as a file on disk and sending emails is not supported.\n" +
|
|
"Sending emails works only for pages opened from the domain."
|
|
);
|
|
else {
|
|
var services = form.find('input[name="formServices"]'),
|
|
l = Const.formActionUrl + "v2/form/process",
|
|
f = url === l;
|
|
if (services.length)
|
|
s(form, {
|
|
url: l,
|
|
method: "POST",
|
|
redirectAddress: i,
|
|
showSuccess: f,
|
|
success: function () {
|
|
if (!f) a(form, { url: url, method: n, redirectAddress: i });
|
|
},
|
|
});
|
|
else a(form, { url: url, method: n, redirectAddress: i });
|
|
}
|
|
},
|
|
click: function (t) {
|
|
t.preventDefault(),
|
|
t.stopPropagation(),
|
|
h(this).find(".u-form-send-success").hide(),
|
|
h(this).find(".u-form-send-error").hide();
|
|
var form = h(this).closest("form");
|
|
if ((o(form), !p.signatureValidation(form)))
|
|
return (
|
|
FormMessage.showError(form, "The Signature field is required"),
|
|
void 0
|
|
);
|
|
if (!f(form))
|
|
return (
|
|
FormMessage.showError(form, "The File field is required"), void 0
|
|
);
|
|
else
|
|
return (
|
|
p.addSignatureFiles(form),
|
|
form.find('input[type="submit"]').click(),
|
|
void 0
|
|
);
|
|
},
|
|
};
|
|
}
|
|
function o(form) {
|
|
form.find(".u-form-checkbox-group").each(function () {
|
|
var t = h(this),
|
|
e = t.find("input"),
|
|
n = e.length,
|
|
i = n > 0 ? e[0] : null,
|
|
o;
|
|
if (e.attr("required") || t.attr("data-required")) {
|
|
e.removeAttr("required"), t.attr("data-required", "required");
|
|
for (var a = false, s = 0; s < n; s++)
|
|
if (e[s].checked) {
|
|
a = true;
|
|
break;
|
|
}
|
|
var u = !a ? "At least one checkbox must be selected." : "";
|
|
i.setCustomValidity(u);
|
|
}
|
|
});
|
|
}
|
|
function a(form, t) {
|
|
if (/list-manage[1-9]?.com/i.test(t.url)) return u(form, t.url), void 0;
|
|
s(form, {
|
|
url: t.url,
|
|
method: t.method,
|
|
redirectAddress: t.redirectAddress,
|
|
success: l,
|
|
showSuccess: true,
|
|
});
|
|
}
|
|
function s(form, t) {
|
|
var e = function () {
|
|
h.ajax({
|
|
type: t.method,
|
|
url: t.url,
|
|
data: new FormData(form[0]),
|
|
dataType: "json",
|
|
processData: false,
|
|
contentType: false,
|
|
})
|
|
.done(function (data, e) {
|
|
if (
|
|
(data && (data.success || data.ok)) ||
|
|
(!data && "success" === e)
|
|
) {
|
|
if (t.showSuccess) FormMessage.showSuccess(form);
|
|
if (t.redirectAddress)
|
|
setTimeout(function () {
|
|
window.location.replace(t.redirectAddress);
|
|
}, 2e3);
|
|
else t.success(form);
|
|
} else (data = data || {}), FormMessage.showError(form, data.error, data.errorId, data.email);
|
|
})
|
|
.fail(function () {
|
|
FormMessage.showError(form);
|
|
});
|
|
};
|
|
if (void 0 !== window.recaptchaObject)
|
|
window.recaptchaObject.executeContact(e);
|
|
else e();
|
|
}
|
|
function u(form, url) {
|
|
var t = form.find("input[name=name]").val(),
|
|
email = form.find("input[name=email]").val(),
|
|
data = { Email: email, EMAIL: email };
|
|
if (t) (data.Name = t), (data.FNAME = t);
|
|
var e = form.find("input, textarea");
|
|
h.each(e, function (index, t) {
|
|
var e = h(t).attr("name"),
|
|
n = h(t).val();
|
|
if (e && n) data[e.toUpperCase()] = n;
|
|
});
|
|
var n =
|
|
(url = url.replace("/post?", "/post-json?") + "&c=?").indexOf("u=") + 2;
|
|
n = url.substring(n, url.indexOf("&", n));
|
|
var i = url.indexOf("id=") + 3;
|
|
(i = url.substring(i, url.indexOf("&", i))),
|
|
(data["b_" + n + "_" + i] = ""),
|
|
h
|
|
.ajax({ url: url, data: data, dataType: "jsonp" })
|
|
.done(function (t) {
|
|
var e;
|
|
if ("success" === t.result || /already/.test(t.msg))
|
|
FormMessage.showSuccess(form), l(form);
|
|
else FormMessage.showError(form, t.msg);
|
|
})
|
|
.fail(function () {
|
|
FormMessage.showError(form);
|
|
});
|
|
}
|
|
function l(form) {
|
|
var dialog = new Dialog(form);
|
|
setTimeout(function () {
|
|
dialog.close();
|
|
}, 2e3);
|
|
}
|
|
function f(form) {
|
|
var t = form.find('input[type="file"][required]');
|
|
if (!t.length) return true;
|
|
else
|
|
return t.toArray().every(function (input) {
|
|
return input.files.length;
|
|
});
|
|
}
|
|
function c(form) {
|
|
var t;
|
|
form.find("input[type=tel]").each(function () {
|
|
var t = h(this),
|
|
e = t.parents(".iti").find(".iti__selected-flag").attr("title") || "";
|
|
t.val(e + " " + t.val());
|
|
});
|
|
}
|
|
var h = n(10),
|
|
Dialog = n(195),
|
|
p = n(9803),
|
|
FormMessage = n(2655),
|
|
Const = n(9804);
|
|
h(function () {
|
|
var form = new i();
|
|
h(
|
|
"form.u-form-vertical:not(.u-form-custom-backend), form.u-form-horizontal:not(.u-form-custom-backend)"
|
|
).submit(form.submit),
|
|
h(".u-form .u-btn-submit").click(form.click);
|
|
}),
|
|
(window.MailChimpForm = i);
|
|
},
|
|
9803: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
var e = JSON.parse(t.getAttribute("data-canvas-default-options") || "{}");
|
|
a(t, e);
|
|
}
|
|
function o(t) {
|
|
var e,
|
|
n = t.clone().get(0),
|
|
i = JSON.parse(n.getAttribute("data-canvas-default-options") || "{}");
|
|
return a(n, i), n.toDataURL();
|
|
}
|
|
function a(t, e) {
|
|
var n = t.getContext("2d");
|
|
n.clearRect(0, 0, e.width, e.height),
|
|
(n.lineWidth = e.lineWidth),
|
|
(n.strokeStyle = e.strokeStyle),
|
|
(n.fillStyle = e.fillStyle),
|
|
n.fillRect(0, 0, e.width, e.height),
|
|
n.beginPath(),
|
|
n.moveTo(e.signatureLine.startX, e.signatureLine.startY),
|
|
n.lineTo(e.signatureLine.endX, e.signatureLine.endY),
|
|
n.stroke();
|
|
}
|
|
function s(t, fileName) {
|
|
for (
|
|
var e = t.split(","),
|
|
n = e[0].match(/:(.*?);/)[1],
|
|
i = atob(e[1]),
|
|
o = i.length,
|
|
a = new Uint8Array(o);
|
|
o--;
|
|
|
|
)
|
|
a[o] = i.charCodeAt(o);
|
|
var s = new Blob([a], { type: n });
|
|
return new File([s], fileName);
|
|
}
|
|
var u = (t.exports = {});
|
|
(u.signatureValidation = function t(form) {
|
|
var e = form.find("canvas"),
|
|
n,
|
|
data;
|
|
if (!e.length) return true;
|
|
if (!e.attr("data-required")) return true;
|
|
else return o(e) !== e.get(0).toDataURL();
|
|
}),
|
|
(u.addSignatureFiles = function t(form) {
|
|
form.find("canvas").each(function () {
|
|
var t = $(this).get(0),
|
|
e,
|
|
n = s(t.toDataURL(), "signature.png"),
|
|
o = form.find(".u-form-signature-file");
|
|
if (o.length) o.remove();
|
|
var file = $(
|
|
'<input class="u-form-signature-file" style="display:none" type="file" name="file">'
|
|
);
|
|
form.append(file);
|
|
var a = new DataTransfer();
|
|
a.items.add(n), (file[0].files = a.files), i(t);
|
|
});
|
|
});
|
|
},
|
|
9804: function (t, e, n) {
|
|
"use strict";
|
|
var Const;
|
|
(t.exports = {}).formActionUrl = [
|
|
"https://forms.",
|
|
"n",
|
|
"i",
|
|
"c",
|
|
"e",
|
|
"p",
|
|
"a",
|
|
"g",
|
|
"e",
|
|
"srv.com/",
|
|
].join("");
|
|
},
|
|
9805: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(485).evaluate,
|
|
o = n(486);
|
|
$(function () {
|
|
function t(t) {
|
|
var form;
|
|
$(t && t.target)
|
|
.closest("form")
|
|
.each(function (index, form) {
|
|
var t = new o(form).getScope();
|
|
$(form)
|
|
.find("[data-expression]")
|
|
.each(function () {
|
|
var e = $(this),
|
|
n = e.closest(".u-form-calc").find(".u-calc-input");
|
|
try {
|
|
var o = e.attr("data-expression"),
|
|
a = i(o, t);
|
|
e.text(a), n.val(a);
|
|
} catch (t) {
|
|
e.text(0), n.val(0);
|
|
}
|
|
});
|
|
});
|
|
}
|
|
$("body").on("input", "input[type=number][name]", t),
|
|
$("body").on(
|
|
"change",
|
|
"input[type=range][name], input[type=radio][name], input[type=checkbox][name], select[name]",
|
|
t
|
|
);
|
|
});
|
|
},
|
|
9806: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
$(".u-form input[type=file]").change(function () {
|
|
var form = $(this).closest(".u-form");
|
|
l(form), f(form);
|
|
});
|
|
}
|
|
function o() {
|
|
$(".u-form .u-upload-button").click(function (t) {
|
|
t.stopPropagation(),
|
|
t.preventDefault(),
|
|
$(this).closest(".u-form").find('input[type="file"]').click();
|
|
});
|
|
}
|
|
function a() {
|
|
$(".u-form").on("click", ".u-file-remove", function (t) {
|
|
t.stopPropagation(), t.preventDefault();
|
|
var e = $(this),
|
|
form = e.closest(".u-form"),
|
|
n = e.closest(".u-file-item"),
|
|
i = parseFloat(n.attr("data-i"));
|
|
if (Number.isFinite(i)) c(form, i), f(form);
|
|
});
|
|
}
|
|
function s() {
|
|
$(".u-form").on("reset", function () {
|
|
var form = $(this).closest(".u-form"),
|
|
input = form.find('input[type="file"]').get(0);
|
|
if (input) (input.files = new DataTransfer().files), f(form);
|
|
});
|
|
}
|
|
function u() {
|
|
$('.u-form input[type="file"]').each(function () {
|
|
var t = $(this),
|
|
e = t.attr("accept");
|
|
if (e in FormFileAccept) e = FormFileAccept[e];
|
|
t.attr("accept", e);
|
|
});
|
|
}
|
|
function l(form) {
|
|
var input = form.find('input[type="file"]').get(0),
|
|
t = [];
|
|
if (input)
|
|
if (
|
|
(Array.from(input.files).forEach(function (file, e) {
|
|
if (file.size > h || e >= p) t.push({ i: e, name: file.name });
|
|
}),
|
|
t.length)
|
|
) {
|
|
c(
|
|
form,
|
|
t.map(function (t) {
|
|
return t.i;
|
|
})
|
|
);
|
|
var e = '"{files}" file(s) size exceeds maximum limit.',
|
|
n = t
|
|
.map(function (t) {
|
|
return t.name;
|
|
})
|
|
.join(", ");
|
|
FormMessage.showError(form, e.replace(/\{files\}/, n));
|
|
}
|
|
}
|
|
function f(form) {
|
|
form.find(".u-file-list .u-file-item:not(.u-file-template)").remove();
|
|
var input = form.find('input[type="file"]').get(0),
|
|
t = form.find(".u-file-template");
|
|
if (input)
|
|
Array.from(input.files).forEach(function (file, e) {
|
|
var n = t.clone();
|
|
n.removeClass("u-file-template"),
|
|
n.find(".u-file-name").text(file.name),
|
|
n.attr("data-i", e),
|
|
form.find(".u-file-list").append(n);
|
|
});
|
|
}
|
|
function c(form, index) {
|
|
var input = form.find('input[type="file"]').get(0),
|
|
t = new DataTransfer();
|
|
if (input) {
|
|
if (!Array.isArray(index)) index = [index];
|
|
Array.from(input.files).forEach(function (file, e) {
|
|
if (!index.includes(e)) t.items.add(file);
|
|
}),
|
|
(input.files = t.files);
|
|
}
|
|
}
|
|
var FormFileAccept = n(489),
|
|
FormMessage = n(2655),
|
|
h = 10 * 1024 * 1024,
|
|
p = 10;
|
|
$(function () {
|
|
i(), o(), a(), s(), u();
|
|
});
|
|
},
|
|
9807: function (t, e, n) {
|
|
"use strict";
|
|
function i(el) {
|
|
var video;
|
|
el.find(".u-video .embed-responsive-item").each(function () {
|
|
if (this.matches("video")) this.pause();
|
|
else if (this.matches("iframe")) {
|
|
var t = this.getAttribute("src");
|
|
this.setAttribute("src", t.replace(/autoplay=1?/gi, ""));
|
|
}
|
|
});
|
|
}
|
|
function o(t) {
|
|
var video;
|
|
(t.hasClass("u-video") ? t : t.find(".u-video"))
|
|
.find(".embed-responsive-item[data-autoplay]")
|
|
.each(function () {
|
|
a(s(this).closest(".u-video"));
|
|
});
|
|
}
|
|
function a(video) {
|
|
if (!video.closest(".u-dialog-block:not(.u-dialog-open)").length) {
|
|
var t = video.find("iframe"),
|
|
e = t.attr("data-src") || t.attr("src"),
|
|
n = video.find("video");
|
|
if (e)
|
|
video.addClass("active"),
|
|
(e += (-1 === e.indexOf("?") ? "?" : "&") + "autoplay=1"),
|
|
t.attr("src", e);
|
|
else if (n.length) {
|
|
video.addClass("active");
|
|
var i = n[0];
|
|
if (i.paused) i.play();
|
|
else i.pause();
|
|
}
|
|
}
|
|
}
|
|
var s = n(10);
|
|
s(document).on("click", ".u-video-poster, .u-video video", function (t) {
|
|
var e, video;
|
|
t.preventDefault(), a(s(this).closest(".u-video"));
|
|
}),
|
|
s(function () {
|
|
s(
|
|
".u-video-background .u-video-poster, .u-video-background .u-video video"
|
|
).each(function () {
|
|
a(s(this).closest(".u-video"));
|
|
}),
|
|
s(
|
|
".u-video .embed-responsive-item:not(.lazyloading, .lazyloaded) + .u-video-poster"
|
|
).each(function () {
|
|
var t = this.getAttribute("data-src");
|
|
if (t) this.style.backgroundImage = "url(" + t + ")";
|
|
o(s(this).closest(".u-video"));
|
|
});
|
|
}),
|
|
s(document).on("opened.np.dialog", ".u-dialog-block", function (t) {
|
|
o(s(t.currentTarget));
|
|
}),
|
|
s(document).on("closed.np.dialog", ".u-dialog-block", function (t) {
|
|
i(s(t.currentTarget));
|
|
});
|
|
},
|
|
9808: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
o = n(9809);
|
|
i(function () {
|
|
new o().init();
|
|
});
|
|
},
|
|
9809: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
(this.galleries = null),
|
|
(this._pswpElement = null),
|
|
(this._listeners = []),
|
|
(this._onItemClick = this.onItemClick.bind(this));
|
|
}
|
|
var Utils = n(9810),
|
|
o = n(9811),
|
|
a = n(9812),
|
|
s = n(9813),
|
|
u = n(10),
|
|
l = n(9814),
|
|
f = n(9815);
|
|
(t.exports = i),
|
|
Object.defineProperty(i.prototype, "pswpElement", {
|
|
get: function () {
|
|
if (!this._pswpElement) this._pswpElement = u(".pswp")[0];
|
|
if (!this._pswpElement) {
|
|
var t = u(a.PSWP_TEMPLATE).appendTo(".u-body");
|
|
this._pswpElement = t[0];
|
|
}
|
|
return this._pswpElement;
|
|
},
|
|
}),
|
|
(i.prototype.init = function () {
|
|
this.initGallery(), this.subscribe(), this.checkHashUrl();
|
|
}),
|
|
(i.prototype.initGallery = function () {
|
|
var t = {};
|
|
u(a.LIGHTBOX_SELECTOR).each(function (t) {
|
|
u(this).attr("data-pswp-uid", t + 1);
|
|
}),
|
|
u(a.GALLERY_ITEM_SELECTOR).each(function () {
|
|
var e = this.closest(a.LIGHTBOX_SELECTOR);
|
|
if (e && this !== e) {
|
|
var n = e.getAttribute("data-pswp-uid"),
|
|
gallery = t[n];
|
|
if (!gallery) gallery = { dom: e, items: [] };
|
|
this.setAttribute("data-pswp-item-id", gallery.items.length),
|
|
this.setAttribute("data-gallery-uid", n),
|
|
gallery.items.push(this),
|
|
(t[n] = gallery);
|
|
}
|
|
}),
|
|
(this.galleries = t);
|
|
}),
|
|
(i.prototype.subscribe = function () {
|
|
for (var t = Object.keys(this.galleries), e = 0; e < t.length; e++)
|
|
for (
|
|
var id = t[e], gallery = this.galleries[id], n = 0;
|
|
n < gallery.items.length;
|
|
n++
|
|
) {
|
|
var i = gallery.items[n];
|
|
u(i).on("click", this._onItemClick);
|
|
}
|
|
}),
|
|
(i.prototype.onItemClick = function (t) {
|
|
var e = t.currentTarget;
|
|
if (!e.matches("[data-href]")) {
|
|
t.preventDefault(), t.stopPropagation(), (t.returnValue = false);
|
|
var index = e.getAttribute("data-pswp-item-id"),
|
|
n = e.getAttribute("data-gallery-uid"),
|
|
gallery = this.galleries[n];
|
|
if (gallery && index >= 0) this.openOnClick(index, gallery);
|
|
}
|
|
}),
|
|
(i.prototype.listen = function (t, e) {
|
|
this._listeners.push({ event: t, func: e });
|
|
}),
|
|
(i.prototype.checkHashUrl = function () {
|
|
var t = Utils.parseHash();
|
|
if (t.pid && t.gid) this.openFromUrl(t.pid, this.galleries[t.gid]);
|
|
}),
|
|
(i.prototype.openOnClick = function (index, gallery) {
|
|
var t = gallery.dom.getAttribute("data-pswp-uid");
|
|
o.gallery(
|
|
gallery,
|
|
function (items) {
|
|
var e = this.buildOptions(t, items);
|
|
(e.index = parseFloat(index)),
|
|
(e.showPreviews =
|
|
gallery.dom.classList.contains("u-product-control")),
|
|
this.showPswp(items, e);
|
|
},
|
|
this
|
|
);
|
|
}),
|
|
(i.prototype.openFromUrl = function (index, gallery) {
|
|
var t = gallery.dom.getAttribute("data-pswp-uid");
|
|
o.gallery(
|
|
gallery,
|
|
function (items) {
|
|
var e = this.buildOptions(t, items);
|
|
if (
|
|
((e.showAnimationDuration = 0),
|
|
(e.index = parseFloat(index) - 1),
|
|
(e.showPreviews =
|
|
gallery.dom.classList.contains("u-product-control")),
|
|
e.galleryPIDs)
|
|
)
|
|
for (var n = 0; n < items.length; n++)
|
|
if (items[n].pid == index) {
|
|
e.index = n;
|
|
break;
|
|
}
|
|
this.showPswp(items, e);
|
|
},
|
|
this
|
|
);
|
|
}),
|
|
(i.prototype.showPswp = function (items, t) {
|
|
if (Number.isFinite(t.index)) {
|
|
var e = new l(this.pswpElement, f, items, t);
|
|
s.init(e, t),
|
|
this._listeners.forEach(function (t) {
|
|
e.listen(t.event, t.func);
|
|
}),
|
|
e.init();
|
|
}
|
|
}),
|
|
(i.prototype.buildOptions = function (t, items) {
|
|
var e;
|
|
return {
|
|
galleryUID: t,
|
|
getThumbBoundsFn: function (index) {
|
|
var t = window.pageYOffset || document.documentElement.scrollTop,
|
|
rect = items[index].el.getBoundingClientRect();
|
|
return { x: rect.left, y: rect.top + t, w: rect.width };
|
|
},
|
|
addCaptionHTMLFn: function (t, e, n) {
|
|
if (n) return (e.children[0].innerHTML = "<br><br>"), true;
|
|
if (!t.title) return (e.children[0].innerHTML = ""), false;
|
|
var i = t.title;
|
|
if (t.desc) i += "<br><small>" + t.desc + "</small>";
|
|
return (e.children[0].innerHTML = i), true;
|
|
},
|
|
showHideOpacity: true,
|
|
history: window.location === window.parent.location,
|
|
};
|
|
}),
|
|
(window.Lightbox = i);
|
|
},
|
|
9810: function (t, e, n) {
|
|
"use strict";
|
|
var Utils;
|
|
(t.exports = {}).parseHash = function t() {
|
|
var hash = window.location.hash.substring(1),
|
|
e = {};
|
|
if (hash.length < 5) return e;
|
|
for (var n = hash.split("&"), i = 0; i < n.length; i++)
|
|
if (n[i]) {
|
|
var o = n[i].split("=");
|
|
if (!(o.length < 2)) e[o[0]] = o[1];
|
|
}
|
|
if (e.gid) e.gid = parseInt(e.gid, 10);
|
|
return e;
|
|
};
|
|
},
|
|
9811: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
return new Promise(function (e, n) {
|
|
if (t.is(".u-background-effect ~ .u-container-layout"))
|
|
i(
|
|
t.prev(".u-background-effect").find(".u-background-effect-image")
|
|
).then(function (t) {
|
|
e(t);
|
|
}, n);
|
|
else if (t.is("img")) {
|
|
var a =
|
|
t[0].naturalWidth ||
|
|
t.attr("data-image-width") ||
|
|
t.attr("imgwidth") ||
|
|
t.width(),
|
|
s =
|
|
t[0].naturalHeight ||
|
|
t.attr("data-image-height") ||
|
|
t.attr("imgheight") ||
|
|
t.height();
|
|
e({
|
|
el: t[0],
|
|
src: t.attr("src"),
|
|
msrc: t.attr("src"),
|
|
w: parseFloat(a),
|
|
h: parseFloat(s),
|
|
});
|
|
} else if (t.is(".u-video"))
|
|
e({ el: t[0], html: t.find(".u-background-video").get(0).outerHTML });
|
|
else if (t.is(".u-gallery-item"))
|
|
i(t.find(".u-back-slide")).then(function (t) {
|
|
e(t);
|
|
}, n);
|
|
else if (t.is(".u-back-slide"))
|
|
i(t.find(".u-back-image")).then(function (n) {
|
|
var i = t.siblings(".u-over-slide"),
|
|
o = t.closest(".u-gallery").is(".u-layout-thumbnails");
|
|
if (i.length && !o)
|
|
(n.title = i.find(".u-gallery-heading").html()),
|
|
(n.desc = i.find(".u-gallery-text").html());
|
|
e(n);
|
|
}, n);
|
|
else
|
|
o(t).then(function (n) {
|
|
e({ el: t[0], src: n.src, msrc: n.src, w: n.width, h: n.height });
|
|
}, n);
|
|
});
|
|
}
|
|
function o(t) {
|
|
var e = t.css("background-image"),
|
|
n = e.match(/url\(['"]?(.+?)['"]?\)/);
|
|
return new Promise(function (t, i) {
|
|
if (n) {
|
|
var o = new Image();
|
|
(o.onload = t.bind(null, o)),
|
|
(o.onerror = o.onabort = i),
|
|
(o.src = n[1]);
|
|
} else i(new Error("Invalid source: " + e));
|
|
});
|
|
}
|
|
var a = n(10),
|
|
s;
|
|
(t.exports = {}).gallery = function gallery(gallery, t, e) {
|
|
e = e || null;
|
|
var n = gallery.items.map(function (t) {
|
|
return i((t = a(t)));
|
|
});
|
|
Promise.all(n).then(t.bind(e), console.log);
|
|
};
|
|
},
|
|
9812: function (t, e, n) {
|
|
"use strict";
|
|
var i = (t.exports = {});
|
|
(i.LIGHTBOX_SELECTOR = ".u-lightbox"),
|
|
(i.GALLERY_ITEM_SELECTOR = [
|
|
".u-image:not(.u-carousel-thumbnail-image):not(.u-background-effect-image)",
|
|
".u-gallery-item",
|
|
".u-background-effect ~ .u-container-layout",
|
|
].join(", ")),
|
|
(i.PSWP_TEMPLATE =
|
|
'<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">\n' +
|
|
' <div class="pswp__bg"></div>\n' +
|
|
' <div class="pswp__scroll-wrap">\n' +
|
|
' <div class="pswp__container">\n' +
|
|
' <div class="pswp__item"></div>\n' +
|
|
' <div class="pswp__item"></div>\n' +
|
|
' <div class="pswp__item"></div>\n' +
|
|
" </div>\n" +
|
|
' <div class="pswp__ui pswp__ui--hidden">\n' +
|
|
' <div class="pswp__top-bar">\n ' +
|
|
' <div class="pswp__counter"></div>\n' +
|
|
' <button class="pswp__button pswp__button--close" title="Close (Esc)"></button>\n' +
|
|
' <button class="pswp__button pswp__button--share" title="Share"></button>\n' +
|
|
' <button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>\n' +
|
|
' <button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>\n' +
|
|
' <div class="pswp__preloader">\n' +
|
|
' <div class="pswp__preloader__icn">\n' +
|
|
' <div class="pswp__preloader__cut">\n' +
|
|
' <div class="pswp__preloader__donut"></div>\n' +
|
|
" </div>\n" +
|
|
" </div>\n" +
|
|
" </div>\n" +
|
|
" </div>\n" +
|
|
' <div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">\n' +
|
|
' <div class="pswp__share-tooltip"></div>\n' +
|
|
" </div>\n" +
|
|
' <button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)"></button>\n' +
|
|
' <button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)"></button>\n' +
|
|
' <div class="pswp__previews" data-previews="data-previews" style="display: none"></div>' +
|
|
' <div class="pswp__caption">\n' +
|
|
' <div class="pswp__caption__center"></div>\n' +
|
|
" </div>\n" +
|
|
" </div>\n" +
|
|
" </div>\n" +
|
|
"</div>");
|
|
},
|
|
9813: function (t, e, n) {
|
|
"use strict";
|
|
function i(gallery, selector) {
|
|
var t = gallery.scrollWrap,
|
|
e = t.querySelector(selector),
|
|
n;
|
|
(t.querySelector(".pswp__caption").style.display = "none"),
|
|
(e.style.display = "");
|
|
}
|
|
function o(gallery, selector) {
|
|
var t = gallery.scrollWrap,
|
|
e = t.querySelector(selector),
|
|
n;
|
|
(t.querySelector(".pswp__caption").style.display = ""),
|
|
(e.style.display = "none");
|
|
}
|
|
function add(gallery, selector) {
|
|
var t = gallery.scrollWrap,
|
|
items = gallery.items,
|
|
e = t.querySelector(selector);
|
|
items.forEach(function (t) {
|
|
var preview = t.msrc,
|
|
n = document.createElement("img");
|
|
n.setAttribute("src", preview),
|
|
n.addEventListener("click", function () {
|
|
gallery.goTo(items.indexOf(t));
|
|
}),
|
|
e.appendChild(n);
|
|
});
|
|
}
|
|
function remove(gallery, selector) {
|
|
var t, e;
|
|
gallery.scrollWrap.querySelector(selector).innerHTML = "";
|
|
}
|
|
function a(gallery, selector) {
|
|
var t = gallery.scrollWrap,
|
|
e,
|
|
preview = gallery.currItem.msrc,
|
|
n,
|
|
i;
|
|
t.querySelector(selector)
|
|
.querySelectorAll("img")
|
|
.forEach(function (t) {
|
|
var e,
|
|
n = "active";
|
|
if (t.getAttribute("src") === preview)
|
|
t.classList.add(n), t.scrollIntoView({ behavior: "smooth" });
|
|
else t.classList.remove(n);
|
|
});
|
|
}
|
|
var s;
|
|
t.exports.init = function init(gallery, t) {
|
|
var e = false;
|
|
gallery.listen("gettingData", function () {
|
|
if (!e) {
|
|
if (((e = true), t.showPreviews)) i(gallery, "[data-previews]");
|
|
else o(gallery, "[data-previews]");
|
|
add(gallery, "[data-previews]");
|
|
}
|
|
}),
|
|
gallery.listen("close", function () {
|
|
remove(gallery, "[data-previews]");
|
|
}),
|
|
gallery.listen("afterChange", function () {
|
|
a(gallery, "[data-previews]");
|
|
});
|
|
};
|
|
},
|
|
9814: function (t, e, n) {
|
|
"use strict";
|
|
var i, o;
|
|
/*! PhotoSwipe - v4.1.3 - 2019-01-08
|
|
* http://photoswipe.com
|
|
* Copyright (c) 2019 Dmitry Semenov; */ !(function (a, factory) {
|
|
if (true)
|
|
!(
|
|
void 0 !==
|
|
(o = "function" == typeof (i = factory) ? i.call(e, n, e, t) : i) &&
|
|
(t.exports = o)
|
|
);
|
|
else if ("object" == typeof e) t.exports = factory();
|
|
else a.PhotoSwipe = factory();
|
|
})(this, function () {
|
|
var t = function (template, t, items, e) {
|
|
var n = {
|
|
features: null,
|
|
bind: function (t, type, e, n) {
|
|
var i = (n ? "remove" : "add") + "EventListener";
|
|
type = type.split(" ");
|
|
for (var o = 0; o < type.length; o++)
|
|
if (type[o]) t[i](type[o], e, false);
|
|
},
|
|
isArray: function (t) {
|
|
return t instanceof Array;
|
|
},
|
|
createEl: function (t, e) {
|
|
var el = document.createElement(e || "div");
|
|
if (t) el.className = t;
|
|
return el;
|
|
},
|
|
getScrollY: function () {
|
|
var t = window.pageYOffset;
|
|
return void 0 !== t ? t : document.documentElement.scrollTop;
|
|
},
|
|
unbind: function (t, type, e) {
|
|
n.bind(t, type, e, true);
|
|
},
|
|
removeClass: function (el, t) {
|
|
var e = new RegExp("(\\s|^)" + t + "(\\s|$)");
|
|
el.className = el.className
|
|
.replace(e, " ")
|
|
.replace(/^\s\s*/, "")
|
|
.replace(/\s\s*$/, "");
|
|
},
|
|
addClass: function (el, t) {
|
|
if (!n.hasClass(el, t))
|
|
el.className += (el.className ? " " : "") + t;
|
|
},
|
|
hasClass: function (el, t) {
|
|
return (
|
|
el.className &&
|
|
new RegExp("(^|\\s)" + t + "(\\s|$)").test(el.className)
|
|
);
|
|
},
|
|
getChildByClass: function (t, e) {
|
|
for (var i = t.firstChild; i;) {
|
|
if (n.hasClass(i, e)) return i;
|
|
i = i.nextSibling;
|
|
}
|
|
},
|
|
arraySearch: function (t, e, n) {
|
|
for (var i = t.length; i--;) if (t[i][n] === e) return i;
|
|
return -1;
|
|
},
|
|
extend: function (t, e, n) {
|
|
for (var i in e)
|
|
if (e.hasOwnProperty(i)) {
|
|
if (n && t.hasOwnProperty(i)) continue;
|
|
t[i] = e[i];
|
|
}
|
|
},
|
|
easing: {
|
|
sine: {
|
|
out: function (t) {
|
|
return Math.sin(t * (Math.PI / 2));
|
|
},
|
|
inOut: function (t) {
|
|
return -(Math.cos(Math.PI * t) - 1) / 2;
|
|
},
|
|
},
|
|
cubic: {
|
|
out: function (t) {
|
|
return --t * t * t + 1;
|
|
},
|
|
},
|
|
},
|
|
detectFeatures: function () {
|
|
if (n.features) return n.features;
|
|
var t,
|
|
e = n.createEl().style,
|
|
i = "",
|
|
o = {};
|
|
if (
|
|
((o.oldIE = document.all && !document.addEventListener),
|
|
(o.touch = "ontouchstart" in window),
|
|
window.requestAnimationFrame)
|
|
)
|
|
(o.raf = window.requestAnimationFrame),
|
|
(o.caf = window.cancelAnimationFrame);
|
|
if (
|
|
((o.pointerEvent =
|
|
!!window.PointerEvent || navigator.msPointerEnabled),
|
|
!o.pointerEvent)
|
|
) {
|
|
var a = navigator.userAgent;
|
|
if (/iP(hone|od)/.test(navigator.platform)) {
|
|
var s = navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/);
|
|
if (s && s.length > 0)
|
|
if ((s = parseInt(s[1], 10)) >= 1 && s < 8)
|
|
o.isOldIOSPhone = true;
|
|
}
|
|
var u = a.match(/Android\s([0-9\.]*)/),
|
|
l = u ? u[1] : 0;
|
|
if ((l = parseFloat(l)) >= 1) {
|
|
if (l < 4.4) o.isOldAndroid = true;
|
|
o.androidVersion = l;
|
|
}
|
|
o.isMobileOpera = /opera mini|opera mobi/i.test(a);
|
|
}
|
|
for (
|
|
var f = ["transform", "perspective", "animationName"],
|
|
c = ["", "webkit", "Moz", "ms", "O"],
|
|
h,
|
|
p,
|
|
m = 0;
|
|
m < 4;
|
|
m++
|
|
) {
|
|
i = c[m];
|
|
for (var v = 0; v < 3; v++)
|
|
if (
|
|
((h = f[v]),
|
|
(p = i + (i ? h.charAt(0).toUpperCase() + h.slice(1) : h)),
|
|
!o[h] && p in e)
|
|
)
|
|
o[h] = p;
|
|
if (i && !o.raf)
|
|
if (
|
|
((i = i.toLowerCase()),
|
|
(o.raf = window[i + "RequestAnimationFrame"]),
|
|
o.raf)
|
|
)
|
|
o.caf =
|
|
window[i + "CancelAnimationFrame"] ||
|
|
window[i + "CancelRequestAnimationFrame"];
|
|
}
|
|
if (!o.raf) {
|
|
var g = 0;
|
|
(o.raf = function (t) {
|
|
var e = new Date().getTime(),
|
|
n = Math.max(0, 16 - (e - g)),
|
|
id = window.setTimeout(function () {
|
|
t(e + n);
|
|
}, n);
|
|
return (g = e + n), id;
|
|
}),
|
|
(o.caf = function (id) {
|
|
clearTimeout(id);
|
|
});
|
|
}
|
|
return (
|
|
(o.svg =
|
|
!!document.createElementNS &&
|
|
!!document.createElementNS("http://www.w3.org/2000/svg", "svg")
|
|
.createSVGRect),
|
|
(n.features = o),
|
|
o
|
|
);
|
|
},
|
|
};
|
|
if ((n.detectFeatures(), n.features.oldIE))
|
|
n.bind = function (t, type, e, n) {
|
|
type = type.split(" ");
|
|
for (
|
|
var i = (n ? "detach" : "attach") + "Event",
|
|
o,
|
|
a = function () {
|
|
e.handleEvent.call(e);
|
|
},
|
|
s = 0;
|
|
s < type.length;
|
|
s++
|
|
)
|
|
if ((o = type[s]))
|
|
if ("object" == typeof e && e.handleEvent) {
|
|
if (!n) e["oldIE" + o] = a;
|
|
else if (!e["oldIE" + o]) return false;
|
|
t[i]("on" + o, e["oldIE" + o]);
|
|
} else t[i]("on" + o, e);
|
|
};
|
|
var i = this,
|
|
o = 25,
|
|
a = 3,
|
|
s = {
|
|
allowPanToNext: true,
|
|
spacing: 0.12,
|
|
bgOpacity: 1,
|
|
mouseUsed: false,
|
|
loop: true,
|
|
pinchToClose: true,
|
|
closeOnScroll: true,
|
|
closeOnVerticalDrag: true,
|
|
verticalDragRange: 0.75,
|
|
hideAnimationDuration: 333,
|
|
showAnimationDuration: 333,
|
|
showHideOpacity: false,
|
|
focus: true,
|
|
escKey: true,
|
|
arrowKeys: true,
|
|
mainScrollEndFriction: 0.35,
|
|
panEndFriction: 0.35,
|
|
isClickableElement: function (el) {
|
|
return "A" === el.tagName;
|
|
},
|
|
getDoubleTapZoom: function (t, e) {
|
|
if (t) return 1;
|
|
else return e.initialZoomLevel < 0.7 ? 1 : 1.33;
|
|
},
|
|
maxSpreadZoom: 1.33,
|
|
modal: true,
|
|
scaleMode: "fit",
|
|
};
|
|
n.extend(s, e);
|
|
var u = function () {
|
|
return { x: 0, y: 0 };
|
|
},
|
|
l,
|
|
f,
|
|
c,
|
|
h,
|
|
p,
|
|
m,
|
|
v = { x: 0, y: 0 },
|
|
g = { x: 0, y: 0 },
|
|
y = { x: 0, y: 0 },
|
|
w,
|
|
b,
|
|
C,
|
|
x = {},
|
|
S,
|
|
A,
|
|
_,
|
|
T,
|
|
I,
|
|
E,
|
|
k = 0,
|
|
M = {},
|
|
L = { x: 0, y: 0 },
|
|
B,
|
|
O,
|
|
P = 0,
|
|
F,
|
|
N,
|
|
z,
|
|
U,
|
|
H,
|
|
$,
|
|
V = true,
|
|
Y,
|
|
W = [],
|
|
j,
|
|
G,
|
|
Z,
|
|
X,
|
|
K,
|
|
J,
|
|
tt,
|
|
nt = {},
|
|
rt = false,
|
|
ot,
|
|
at = function (t, e) {
|
|
n.extend(i, e.publicMethods), W.push(t);
|
|
},
|
|
st = function (index) {
|
|
var t = wn();
|
|
if (index > t - 1) return index - t;
|
|
else if (index < 0) return t + index;
|
|
return index;
|
|
},
|
|
ut = {},
|
|
lt = function (t, e) {
|
|
if (!ut[t]) ut[t] = [];
|
|
return ut[t].push(e);
|
|
},
|
|
ft = function (t) {
|
|
var e = ut[t];
|
|
if (e) {
|
|
var n = Array.prototype.slice.call(arguments);
|
|
n.shift();
|
|
for (var o = 0; o < e.length; o++) e[o].apply(i, n);
|
|
}
|
|
},
|
|
ct = function () {
|
|
return new Date().getTime();
|
|
},
|
|
dt = function (t) {
|
|
(Le = t), (i.bg.style.opacity = t * s.bgOpacity);
|
|
},
|
|
ht = function (t, e, n, o, a) {
|
|
if (!rt || (a && a !== i.currItem))
|
|
o /= a ? a.fitRatio : i.currItem.fitRatio;
|
|
t[H] = _ + e + "px, " + n + "px" + T + " scale(" + o + ")";
|
|
},
|
|
pt = function (t) {
|
|
if (Se) {
|
|
if (t)
|
|
if (S > i.currItem.fitRatio) {
|
|
if (!rt) In(i.currItem, false, true), (rt = true);
|
|
} else if (rt) In(i.currItem), (rt = false);
|
|
ht(Se, y.x, y.y, S);
|
|
}
|
|
},
|
|
mt = function (t) {
|
|
if (t.container)
|
|
ht(
|
|
t.container.style,
|
|
t.initialPosition.x,
|
|
t.initialPosition.y,
|
|
t.initialZoomLevel,
|
|
t
|
|
);
|
|
},
|
|
vt = function (t, e) {
|
|
e[H] = _ + t + "px, 0px" + T;
|
|
},
|
|
gt = function (t, e) {
|
|
if (!s.loop && e) {
|
|
var n = h + (L.x * k - t) / L.x,
|
|
i = Math.round(t - xe.x);
|
|
if ((n < 0 && i > 0) || (n >= wn() - 1 && i < 0))
|
|
t = xe.x + i * s.mainScrollEndFriction;
|
|
}
|
|
(xe.x = t), vt(t, p);
|
|
},
|
|
yt = function (t, e) {
|
|
var n = _e[t] - M[t];
|
|
return g[t] + v[t] + n - n * (e / A);
|
|
},
|
|
wt = function (t, e) {
|
|
if (((t.x = e.x), (t.y = e.y), e.id)) t.id = e.id;
|
|
},
|
|
bt = function (t) {
|
|
(t.x = Math.round(t.x)), (t.y = Math.round(t.y));
|
|
},
|
|
Ct = null,
|
|
xt = function () {
|
|
if (Ct)
|
|
n.unbind(document, "mousemove", xt),
|
|
n.addClass(template, "pswp--has_mouse"),
|
|
(s.mouseUsed = true),
|
|
ft("mouseUsed");
|
|
Ct = setTimeout(function () {
|
|
Ct = null;
|
|
}, 100);
|
|
},
|
|
St = function () {
|
|
if ((n.bind(document, "keydown", i), tt.transform))
|
|
n.bind(i.scrollWrap, "click", i);
|
|
if (!s.mouseUsed) n.bind(document, "mousemove", xt);
|
|
n.bind(window, "resize scroll orientationchange", i),
|
|
ft("bindEvents");
|
|
},
|
|
At = function () {
|
|
if (
|
|
(n.unbind(window, "resize scroll orientationchange", i),
|
|
n.unbind(window, "scroll", C.scroll),
|
|
n.unbind(document, "keydown", i),
|
|
n.unbind(document, "mousemove", xt),
|
|
tt.transform)
|
|
)
|
|
n.unbind(i.scrollWrap, "click", i);
|
|
if (ue) n.unbind(window, w, i);
|
|
clearTimeout(ot), ft("unbindEvents");
|
|
},
|
|
_t = function (t, update) {
|
|
var e = Sn(i.currItem, x, t);
|
|
if (update) Ce = e;
|
|
return e;
|
|
},
|
|
Tt = function (t) {
|
|
if (!t) t = i.currItem;
|
|
return t.initialZoomLevel;
|
|
},
|
|
Dt = function (t) {
|
|
if (!t) t = i.currItem;
|
|
return t.w > 0 ? s.maxSpreadZoom : 1;
|
|
},
|
|
kt = function (t, e, n, o) {
|
|
if (o === i.currItem.initialZoomLevel)
|
|
return (n[t] = i.currItem.initialPosition[t]), true;
|
|
else if (((n[t] = yt(t, o)), n[t] > e.min[t]))
|
|
return (n[t] = e.min[t]), true;
|
|
else if (n[t] < e.max[t]) return (n[t] = e.max[t]), true;
|
|
return false;
|
|
},
|
|
Mt = function () {
|
|
if (H) {
|
|
var t = tt.perspective && !Y;
|
|
return (
|
|
(_ = "translate" + (t ? "3d(" : "(")),
|
|
(T = tt.perspective ? ", 0px)" : ")"),
|
|
void 0
|
|
);
|
|
}
|
|
(H = "left"),
|
|
n.addClass(template, "pswp--ie"),
|
|
(vt = function (t, e) {
|
|
e.left = t + "px";
|
|
}),
|
|
(mt = function (t) {
|
|
var e = t.fitRatio > 1 ? 1 : t.fitRatio,
|
|
n = t.container.style,
|
|
i = e * t.w,
|
|
o = e * t.h;
|
|
(n.width = i + "px"),
|
|
(n.height = o + "px"),
|
|
(n.left = t.initialPosition.x + "px"),
|
|
(n.top = t.initialPosition.y + "px");
|
|
}),
|
|
(pt = function () {
|
|
if (Se) {
|
|
var t = Se,
|
|
e = i.currItem,
|
|
n = e.fitRatio > 1 ? 1 : e.fitRatio,
|
|
o = n * e.w,
|
|
a = n * e.h;
|
|
(t.width = o + "px"),
|
|
(t.height = a + "px"),
|
|
(t.left = y.x + "px"),
|
|
(t.top = y.y + "px");
|
|
}
|
|
});
|
|
},
|
|
Lt = function (t) {
|
|
var e = "";
|
|
if (s.escKey && 27 === t.keyCode) e = "close";
|
|
else if (s.arrowKeys)
|
|
if (37 === t.keyCode) e = "prev";
|
|
else if (39 === t.keyCode) e = "next";
|
|
if (e)
|
|
if (!(t.ctrlKey || t.altKey || t.shiftKey || t.metaKey)) {
|
|
if (t.preventDefault) t.preventDefault();
|
|
else t.returnValue = false;
|
|
i[e]();
|
|
}
|
|
},
|
|
Bt = function (t) {
|
|
if (t)
|
|
if (ce || fe || Ae || ie) t.preventDefault(), t.stopPropagation();
|
|
},
|
|
Ot = function () {
|
|
i.setScrollOffset(0, n.getScrollY());
|
|
},
|
|
Pt = {},
|
|
Ft = 0,
|
|
Rt = function (t) {
|
|
if (Pt[t]) {
|
|
if (Pt[t].raf) G(Pt[t].raf);
|
|
Ft--, delete Pt[t];
|
|
}
|
|
},
|
|
Nt = function (t) {
|
|
if (Pt[t]) Rt(t);
|
|
if (!Pt[t]) Ft++, (Pt[t] = {});
|
|
},
|
|
zt = function () {
|
|
for (var t in Pt) if (Pt.hasOwnProperty(t)) Rt(t);
|
|
},
|
|
Ut = function (t, e, n, d, i, o, a) {
|
|
var s = ct(),
|
|
u;
|
|
Nt(t);
|
|
var l = function () {
|
|
if (Pt[t]) {
|
|
if ((u = ct() - s) >= d) {
|
|
if ((Rt(t), o(n), a)) a();
|
|
return;
|
|
}
|
|
o((n - e) * i(u / d) + e), (Pt[t].raf = j(l));
|
|
}
|
|
};
|
|
l();
|
|
},
|
|
qt = {
|
|
shout: ft,
|
|
listen: lt,
|
|
viewportSize: x,
|
|
options: s,
|
|
isMainScrollAnimating: function () {
|
|
return Ae;
|
|
},
|
|
getZoomLevel: function () {
|
|
return S;
|
|
},
|
|
getCurrentIndex: function () {
|
|
return h;
|
|
},
|
|
isDragging: function () {
|
|
return ue;
|
|
},
|
|
isZooming: function () {
|
|
return ye;
|
|
},
|
|
setScrollOffset: function (t, e) {
|
|
(M.x = t), (J = M.y = e), ft("updateScrollOffset", M);
|
|
},
|
|
applyZoomPan: function (t, e, n, i) {
|
|
(y.x = e), (y.y = n), (S = t), pt(i);
|
|
},
|
|
init: function () {
|
|
if (!l && !f) {
|
|
var e;
|
|
(i.framework = n),
|
|
(i.template = template),
|
|
(i.bg = n.getChildByClass(template, "pswp__bg")),
|
|
(Z = template.className),
|
|
(l = true),
|
|
(tt = n.detectFeatures()),
|
|
(j = tt.raf),
|
|
(G = tt.caf),
|
|
(H = tt.transform),
|
|
(K = tt.oldIE),
|
|
(i.scrollWrap = n.getChildByClass(
|
|
template,
|
|
"pswp__scroll-wrap"
|
|
)),
|
|
(i.container = n.getChildByClass(
|
|
i.scrollWrap,
|
|
"pswp__container"
|
|
)),
|
|
(p = i.container.style),
|
|
(i.itemHolders = B =
|
|
[
|
|
{ el: i.container.children[0], wrap: 0, index: -1 },
|
|
{ el: i.container.children[1], wrap: 0, index: -1 },
|
|
{ el: i.container.children[2], wrap: 0, index: -1 },
|
|
]),
|
|
(B[0].el.style.display = B[2].el.style.display = "none"),
|
|
Mt(),
|
|
(C = {
|
|
resize: i.updateSize,
|
|
orientationchange: function () {
|
|
clearTimeout(ot),
|
|
(ot = setTimeout(function () {
|
|
if (x.x !== i.scrollWrap.clientWidth) i.updateSize();
|
|
}, 500));
|
|
},
|
|
scroll: Ot,
|
|
keydown: Lt,
|
|
click: Bt,
|
|
});
|
|
var o = tt.isOldIOSPhone || tt.isOldAndroid || tt.isMobileOpera;
|
|
if (!tt.animationName || !tt.transform || o)
|
|
s.showAnimationDuration = s.hideAnimationDuration = 0;
|
|
for (e = 0; e < W.length; e++) i["init" + W[e]]();
|
|
if (t) {
|
|
var u;
|
|
(i.ui = new t(i, n)).init();
|
|
}
|
|
if (
|
|
(ft("firstUpdate"),
|
|
(h = h || s.index || 0),
|
|
isNaN(h) || h < 0 || h >= wn())
|
|
)
|
|
h = 0;
|
|
if (((i.currItem = yn(h)), tt.isOldIOSPhone || tt.isOldAndroid))
|
|
V = false;
|
|
if ((template.setAttribute("aria-hidden", "false"), s.modal))
|
|
if (!V)
|
|
(template.style.position = "absolute"),
|
|
(template.style.top = n.getScrollY() + "px");
|
|
else template.style.position = "fixed";
|
|
if (void 0 === J) ft("initialLayout"), (J = X = n.getScrollY());
|
|
var c = "pswp--open ";
|
|
if (s.mainClass) c += s.mainClass + " ";
|
|
if (s.showHideOpacity) c += "pswp--animate_opacity ";
|
|
for (
|
|
c += Y ? "pswp--touch" : "pswp--notouch",
|
|
c += tt.animationName ? " pswp--css_animation" : "",
|
|
c += tt.svg ? " pswp--svg" : "",
|
|
n.addClass(template, c),
|
|
i.updateSize(),
|
|
m = -1,
|
|
P = null,
|
|
e = 0;
|
|
e < a;
|
|
e++
|
|
)
|
|
vt((e + m) * L.x, B[e].el.style);
|
|
if (!K) n.bind(i.scrollWrap, b, i);
|
|
if (
|
|
(lt("initialZoomInEnd", function () {
|
|
if (
|
|
(i.setContent(B[0], h - 1),
|
|
i.setContent(B[2], h + 1),
|
|
(B[0].el.style.display = B[2].el.style.display = "block"),
|
|
s.focus)
|
|
)
|
|
template.focus();
|
|
St();
|
|
}),
|
|
i.setContent(B[1], h),
|
|
i.updateCurrItem(),
|
|
ft("afterInit"),
|
|
!V)
|
|
)
|
|
I = setInterval(function () {
|
|
if (!Ft && !ue && !ye && S === i.currItem.initialZoomLevel)
|
|
i.updateSize();
|
|
}, 1e3);
|
|
n.addClass(template, "pswp--visible");
|
|
}
|
|
},
|
|
close: function () {
|
|
if (l)
|
|
(l = false),
|
|
(f = true),
|
|
ft("close"),
|
|
At(),
|
|
cn(i.currItem, null, true, i.destroy);
|
|
},
|
|
destroy: function () {
|
|
if ((ft("destroy"), fn)) clearTimeout(fn);
|
|
if (
|
|
(template.setAttribute("aria-hidden", "true"),
|
|
(template.className = Z),
|
|
I)
|
|
)
|
|
clearInterval(I);
|
|
n.unbind(i.scrollWrap, b, i),
|
|
n.unbind(window, "scroll", i),
|
|
Re(),
|
|
zt(),
|
|
(ut = null);
|
|
},
|
|
panTo: function (t, e, n) {
|
|
if (!n) {
|
|
if (t > Ce.min.x) t = Ce.min.x;
|
|
else if (t < Ce.max.x) t = Ce.max.x;
|
|
if (e > Ce.min.y) e = Ce.min.y;
|
|
else if (e < Ce.max.y) e = Ce.max.y;
|
|
}
|
|
(y.x = t), (y.y = e), pt();
|
|
},
|
|
handleEvent: function (t) {
|
|
if (((t = t || window.event), C[t.type])) C[t.type](t);
|
|
},
|
|
goTo: function (index) {
|
|
var diff = (index = st(index)) - h;
|
|
(P = diff),
|
|
(h = index),
|
|
(i.currItem = yn(h)),
|
|
(k -= diff),
|
|
gt(L.x * k),
|
|
zt(),
|
|
(Ae = false),
|
|
i.updateCurrItem();
|
|
},
|
|
next: function () {
|
|
i.goTo(h + 1);
|
|
},
|
|
prev: function () {
|
|
i.goTo(h - 1);
|
|
},
|
|
updateCurrZoomItem: function (t) {
|
|
if (t) ft("beforeChange", 0);
|
|
if (B[1].el.children.length) {
|
|
var e = B[1].el.children[0];
|
|
if (n.hasClass(e, "pswp__zoom-wrap")) Se = e.style;
|
|
else Se = null;
|
|
} else Se = null;
|
|
if (
|
|
((Ce = i.currItem.bounds),
|
|
(A = S = i.currItem.initialZoomLevel),
|
|
(y.x = Ce.center.x),
|
|
(y.y = Ce.center.y),
|
|
t)
|
|
)
|
|
ft("afterChange");
|
|
},
|
|
invalidateCurrItems: function () {
|
|
E = true;
|
|
for (var t = 0; t < a; t++)
|
|
if (B[t].item) B[t].item.needsUpdate = true;
|
|
},
|
|
updateCurrItem: function (t) {
|
|
if (0 !== P) {
|
|
var e = Math.abs(P),
|
|
n;
|
|
if (!(t && e < 2)) {
|
|
if (
|
|
((i.currItem = yn(h)),
|
|
(rt = false),
|
|
ft("beforeChange", P),
|
|
e >= a)
|
|
)
|
|
(m += P + (P > 0 ? -a : a)), (e = a);
|
|
for (var o = 0; o < e; o++)
|
|
if (P > 0)
|
|
(n = B.shift()),
|
|
(B[a - 1] = n),
|
|
m++,
|
|
vt((m + 2) * L.x, n.el.style),
|
|
i.setContent(n, h - e + o + 1 + 1);
|
|
else
|
|
(n = B.pop()),
|
|
B.unshift(n),
|
|
m--,
|
|
vt(m * L.x, n.el.style),
|
|
i.setContent(n, h + e - o - 1 - 1);
|
|
if (Se && 1 === Math.abs(P)) {
|
|
var s = yn(O);
|
|
if (s.initialZoomLevel !== S) Sn(s, x), In(s), mt(s);
|
|
}
|
|
(P = 0), i.updateCurrZoomItem(), (O = h), ft("afterChange");
|
|
}
|
|
}
|
|
},
|
|
updateSize: function (t) {
|
|
if (!V && s.modal) {
|
|
var e = n.getScrollY();
|
|
if (J !== e) (template.style.top = e + "px"), (J = e);
|
|
if (
|
|
!t &&
|
|
nt.x === window.innerWidth &&
|
|
nt.y === window.innerHeight
|
|
)
|
|
return;
|
|
(nt.x = window.innerWidth),
|
|
(nt.y = window.innerHeight),
|
|
(template.style.height = nt.y + "px");
|
|
}
|
|
if (
|
|
((x.x = i.scrollWrap.clientWidth),
|
|
(x.y = i.scrollWrap.clientHeight),
|
|
Ot(),
|
|
(L.x = x.x + Math.round(x.x * s.spacing)),
|
|
(L.y = x.y),
|
|
gt(L.x * k),
|
|
ft("beforeResize"),
|
|
void 0 !== m)
|
|
) {
|
|
for (var o, u, l, f = 0; f < a; f++) {
|
|
if (
|
|
((o = B[f]),
|
|
vt((f + m) * L.x, o.el.style),
|
|
(l = h + f - 1),
|
|
s.loop && wn() > 2)
|
|
)
|
|
l = st(l);
|
|
if ((u = yn(l)) && (E || u.needsUpdate || !u.bounds)) {
|
|
if ((i.cleanSlide(u), i.setContent(o, l), 1 === f))
|
|
(i.currItem = u), i.updateCurrZoomItem(true);
|
|
u.needsUpdate = false;
|
|
} else if (-1 === o.index && l >= 0) i.setContent(o, l);
|
|
if (u && u.container) Sn(u, x), In(u), mt(u);
|
|
}
|
|
E = false;
|
|
}
|
|
if (
|
|
((A = S = i.currItem.initialZoomLevel),
|
|
(Ce = i.currItem.bounds))
|
|
)
|
|
(y.x = Ce.center.x), (y.y = Ce.center.y), pt(true);
|
|
ft("resize");
|
|
},
|
|
zoomTo: function (t, e, i, o, a) {
|
|
if (e)
|
|
(A = S),
|
|
(_e.x = Math.abs(e.x) - y.x),
|
|
(_e.y = Math.abs(e.y) - y.y),
|
|
wt(g, y);
|
|
var s = _t(t, false),
|
|
u = {};
|
|
kt("x", s, u, t), kt("y", s, u, t);
|
|
var l = S,
|
|
f = y.x,
|
|
c = y.y;
|
|
bt(u);
|
|
var h = function (e) {
|
|
if (1 === e) (S = t), (y.x = u.x), (y.y = u.y);
|
|
else
|
|
(S = (t - l) * e + l),
|
|
(y.x = (u.x - f) * e + f),
|
|
(y.y = (u.y - c) * e + c);
|
|
if (a) a(e);
|
|
pt(1 === e);
|
|
};
|
|
if (i) Ut("customZoomTo", 0, 1, i, o || n.easing.sine.inOut, h);
|
|
else h(1);
|
|
},
|
|
},
|
|
Ht = 30,
|
|
$t = 10,
|
|
Vt,
|
|
Yt,
|
|
Wt = {},
|
|
jt = {},
|
|
Gt = {},
|
|
Zt = {},
|
|
Xt = {},
|
|
Kt = [],
|
|
Jt = {},
|
|
Qt,
|
|
te = [],
|
|
ee = {},
|
|
ne,
|
|
ie,
|
|
re,
|
|
oe = 0,
|
|
ae = { x: 0, y: 0 },
|
|
se = 0,
|
|
ue,
|
|
le,
|
|
fe,
|
|
ce,
|
|
pe,
|
|
ve,
|
|
ge,
|
|
ye,
|
|
we,
|
|
be,
|
|
Ce,
|
|
xe = { x: 0, y: 0 },
|
|
Se,
|
|
Ae,
|
|
_e = { x: 0, y: 0 },
|
|
Te = { x: 0, y: 0 },
|
|
Ie,
|
|
Ee,
|
|
ke,
|
|
Le,
|
|
Be,
|
|
Oe = function (t, e) {
|
|
return t.x === e.x && t.y === e.y;
|
|
},
|
|
Pe = function (t, e) {
|
|
return Math.abs(t.x - e.x) < o && Math.abs(t.y - e.y) < o;
|
|
},
|
|
Fe = function (t, e) {
|
|
return (
|
|
(ee.x = Math.abs(t.x - e.x)),
|
|
(ee.y = Math.abs(t.y - e.y)),
|
|
Math.sqrt(ee.x * ee.x + ee.y * ee.y)
|
|
);
|
|
},
|
|
Re = function () {
|
|
if (pe) G(pe), (pe = null);
|
|
},
|
|
Ne = function () {
|
|
if (ue) (pe = j(Ne)), nn();
|
|
},
|
|
ze = function () {
|
|
return !(
|
|
"fit" === s.scaleMode && S === i.currItem.initialZoomLevel
|
|
);
|
|
},
|
|
Ue = function (el, t) {
|
|
if (!el || el === document) return false;
|
|
if (
|
|
el.getAttribute("class") &&
|
|
el.getAttribute("class").indexOf("pswp__scroll-wrap") > -1
|
|
)
|
|
return false;
|
|
if (t(el)) return el;
|
|
else return Ue(el.parentNode, t);
|
|
},
|
|
qe = {},
|
|
$e = function (t, e) {
|
|
return (
|
|
(qe.prevent = !Ue(t.target, s.isClickableElement)),
|
|
ft("preventDragEvent", t, e, qe),
|
|
qe.prevent
|
|
);
|
|
},
|
|
Ve = function (t, e) {
|
|
return (e.x = t.pageX), (e.y = t.pageY), (e.id = t.identifier), e;
|
|
},
|
|
Ye = function (t, e, n) {
|
|
(n.x = 0.5 * (t.x + e.x)), (n.y = 0.5 * (t.y + e.y));
|
|
},
|
|
We = function (t, e, n) {
|
|
if (t - Yt > 50) {
|
|
var i = te.length > 2 ? te.shift() : {};
|
|
(i.x = e), (i.y = n), te.push(i), (Yt = t);
|
|
}
|
|
},
|
|
je = function () {
|
|
var t = y.y - i.currItem.initialPosition.y;
|
|
return 1 - Math.abs(t / (x.y / 2));
|
|
},
|
|
Ge = {},
|
|
Ze = {},
|
|
Xe = [],
|
|
Ke,
|
|
Je = function (t) {
|
|
for (; Xe.length > 0;) Xe.pop();
|
|
if (!$)
|
|
if (t.type.indexOf("touch") > -1) {
|
|
if (t.touches && t.touches.length > 0)
|
|
if (((Xe[0] = Ve(t.touches[0], Ge)), t.touches.length > 1))
|
|
Xe[1] = Ve(t.touches[1], Ze);
|
|
} else
|
|
(Ge.x = t.pageX), (Ge.y = t.pageY), (Ge.id = ""), (Xe[0] = Ge);
|
|
else
|
|
(Ke = 0),
|
|
Kt.forEach(function (t) {
|
|
if (0 === Ke) Xe[0] = t;
|
|
else if (1 === Ke) Xe[1] = t;
|
|
Ke++;
|
|
});
|
|
return Xe;
|
|
},
|
|
Qe = function (t, e) {
|
|
var n,
|
|
o = 0,
|
|
a = y[t] + e[t],
|
|
u,
|
|
l = e[t] > 0,
|
|
f = xe.x + e.x,
|
|
c = xe.x - Jt.x,
|
|
h,
|
|
p;
|
|
if (a > Ce.min[t] || a < Ce.max[t]) n = s.panEndFriction;
|
|
else n = 1;
|
|
if (
|
|
((a = y[t] + e[t] * n),
|
|
s.allowPanToNext || S === i.currItem.initialZoomLevel)
|
|
) {
|
|
if (!Se) p = f;
|
|
else if ("h" === Ie && "x" === t && !fe)
|
|
if (l) {
|
|
if (a > Ce.min[t])
|
|
(n = s.panEndFriction),
|
|
(o = Ce.min[t] - a),
|
|
(u = Ce.min[t] - g[t]);
|
|
if ((u <= 0 || c < 0) && wn() > 1) {
|
|
if (((p = f), c < 0 && f > Jt.x)) p = Jt.x;
|
|
} else if (Ce.min.x !== Ce.max.x) h = a;
|
|
} else {
|
|
if (a < Ce.max[t])
|
|
(n = s.panEndFriction),
|
|
(o = a - Ce.max[t]),
|
|
(u = g[t] - Ce.max[t]);
|
|
if ((u <= 0 || c > 0) && wn() > 1) {
|
|
if (((p = f), c > 0 && f < Jt.x)) p = Jt.x;
|
|
} else if (Ce.min.x !== Ce.max.x) h = a;
|
|
}
|
|
if ("x" === t) {
|
|
if (void 0 !== p)
|
|
if ((gt(p, true), p === Jt.x)) ve = false;
|
|
else ve = true;
|
|
if (Ce.min.x !== Ce.max.x)
|
|
if (void 0 !== h) y.x = h;
|
|
else if (!ve) y.x += e.x * n;
|
|
return void 0 !== p;
|
|
}
|
|
}
|
|
if (!Ae) if (!ve) if (S > i.currItem.fitRatio) y[t] += e[t] * n;
|
|
},
|
|
tn = function (t) {
|
|
if (!("mousedown" === t.type && t.button > 0)) {
|
|
if (vn) return t.preventDefault(), void 0;
|
|
if (!re || "mousedown" !== t.type) {
|
|
if ($e(t, true)) t.preventDefault();
|
|
if ((ft("pointerDown"), $)) {
|
|
var e = n.arraySearch(Kt, t.pointerId, "id");
|
|
if (e < 0) e = Kt.length;
|
|
Kt[e] = { x: t.pageX, y: t.pageY, id: t.pointerId };
|
|
}
|
|
var o = Je(t),
|
|
a = o.length;
|
|
if (((ge = null), zt(), !ue || 1 === a))
|
|
(ue = Ee = true),
|
|
n.bind(window, w, i),
|
|
(ne = Be = ke = ie = ve = ce = le = fe = false),
|
|
(Ie = null),
|
|
ft("firstTouchStart", o),
|
|
wt(g, y),
|
|
(v.x = v.y = 0),
|
|
wt(Zt, o[0]),
|
|
wt(Xt, Zt),
|
|
(Jt.x = L.x * k),
|
|
(te = [{ x: Zt.x, y: Zt.y }]),
|
|
(Yt = Vt = ct()),
|
|
_t(S, true),
|
|
Re(),
|
|
Ne();
|
|
if (!ye && a > 1 && !Ae && !ve)
|
|
(A = S),
|
|
(fe = false),
|
|
(ye = le = true),
|
|
(v.y = v.x = 0),
|
|
wt(g, y),
|
|
wt(Wt, o[0]),
|
|
wt(jt, o[1]),
|
|
Ye(Wt, jt, Te),
|
|
(_e.x = Math.abs(Te.x) - y.x),
|
|
(_e.y = Math.abs(Te.y) - y.y),
|
|
(we = be = Fe(Wt, jt));
|
|
}
|
|
}
|
|
},
|
|
en = function (t) {
|
|
if ((t.preventDefault(), $)) {
|
|
var e = n.arraySearch(Kt, t.pointerId, "id");
|
|
if (e > -1) {
|
|
var i = Kt[e];
|
|
(i.x = t.pageX), (i.y = t.pageY);
|
|
}
|
|
}
|
|
if (ue) {
|
|
var o = Je(t);
|
|
if (!Ie && !ce && !ye)
|
|
if (xe.x !== L.x * k) Ie = "h";
|
|
else {
|
|
var diff = Math.abs(o[0].x - Zt.x) - Math.abs(o[0].y - Zt.y);
|
|
if (Math.abs(diff) >= $t)
|
|
(Ie = diff > 0 ? "h" : "v"), (ge = o);
|
|
}
|
|
else ge = o;
|
|
}
|
|
},
|
|
nn = function () {
|
|
if (ge) {
|
|
var t = ge.length;
|
|
if (0 !== t)
|
|
if (
|
|
(wt(Wt, ge[0]),
|
|
(Gt.x = Wt.x - Zt.x),
|
|
(Gt.y = Wt.y - Zt.y),
|
|
ye && t > 1)
|
|
) {
|
|
if (
|
|
((Zt.x = Wt.x),
|
|
(Zt.y = Wt.y),
|
|
!Gt.x && !Gt.y && Oe(ge[1], jt))
|
|
)
|
|
return;
|
|
if ((wt(jt, ge[1]), !fe))
|
|
(fe = true), ft("zoomGestureStarted");
|
|
var e = Fe(Wt, jt),
|
|
n = un(e);
|
|
if (
|
|
n >
|
|
i.currItem.initialZoomLevel +
|
|
i.currItem.initialZoomLevel / 15
|
|
)
|
|
Be = true;
|
|
var o = 1,
|
|
a = Tt(),
|
|
u = Dt();
|
|
if (n < a)
|
|
if (
|
|
s.pinchToClose &&
|
|
!Be &&
|
|
A <= i.currItem.initialZoomLevel
|
|
) {
|
|
var l,
|
|
f = 1 - (a - n) / (a / 1.2);
|
|
dt(f), ft("onPinchClose", f), (ke = true);
|
|
} else {
|
|
if ((o = (a - n) / a) > 1) o = 1;
|
|
n = a - o * (a / 3);
|
|
}
|
|
else if (n > u) {
|
|
if ((o = (n - u) / (6 * a)) > 1) o = 1;
|
|
n = u + o * a;
|
|
}
|
|
if (o < 0) o = 0;
|
|
(we = e),
|
|
Ye(Wt, jt, ae),
|
|
(v.x += ae.x - Te.x),
|
|
(v.y += ae.y - Te.y),
|
|
wt(Te, ae),
|
|
(y.x = yt("x", n)),
|
|
(y.y = yt("y", n)),
|
|
(ne = n > S),
|
|
(S = n),
|
|
pt();
|
|
} else {
|
|
if (!Ie) return;
|
|
if (Ee) {
|
|
if (((Ee = false), Math.abs(Gt.x) >= $t))
|
|
Gt.x -= ge[0].x - Xt.x;
|
|
if (Math.abs(Gt.y) >= $t) Gt.y -= ge[0].y - Xt.y;
|
|
}
|
|
if (((Zt.x = Wt.x), (Zt.y = Wt.y), 0 === Gt.x && 0 === Gt.y))
|
|
return;
|
|
if ("v" === Ie && s.closeOnVerticalDrag)
|
|
if (!ze()) {
|
|
(v.y += Gt.y), (y.y += Gt.y);
|
|
var c = je();
|
|
return (
|
|
(ie = true),
|
|
ft("onVerticalDrag", c),
|
|
dt(c),
|
|
pt(),
|
|
void 0
|
|
);
|
|
}
|
|
var h;
|
|
if (
|
|
(We(ct(), Wt.x, Wt.y),
|
|
(ce = true),
|
|
(Ce = i.currItem.bounds),
|
|
!Qe("x", Gt))
|
|
)
|
|
Qe("y", Gt), bt(y), pt();
|
|
}
|
|
}
|
|
},
|
|
rn = function (t) {
|
|
if (tt.isOldAndroid) {
|
|
if (re && "mouseup" === t.type) return;
|
|
if (t.type.indexOf("touch") > -1)
|
|
clearTimeout(re),
|
|
(re = setTimeout(function () {
|
|
re = 0;
|
|
}, 600));
|
|
}
|
|
if ((ft("pointerUp"), $e(t, false))) t.preventDefault();
|
|
var e;
|
|
if ($) {
|
|
var o = n.arraySearch(Kt, t.pointerId, "id");
|
|
if (o > -1)
|
|
if (((e = Kt.splice(o, 1)[0]), navigator.msPointerEnabled)) {
|
|
var a = { 4: "mouse", 2: "touch", 3: "pen" };
|
|
if (((e.type = a[t.pointerType]), !e.type))
|
|
e.type = t.pointerType || "mouse";
|
|
} else e.type = t.pointerType || "mouse";
|
|
}
|
|
var u = Je(t),
|
|
l,
|
|
f = u.length;
|
|
if ("mouseup" === t.type) f = 0;
|
|
if (2 === f) return (ge = null), true;
|
|
if (1 === f) wt(Xt, u[0]);
|
|
if (0 === f && !Ie && !Ae) {
|
|
if (!e)
|
|
if ("mouseup" === t.type)
|
|
e = { x: t.pageX, y: t.pageY, type: "mouse" };
|
|
else if (t.changedTouches && t.changedTouches[0])
|
|
e = {
|
|
x: t.changedTouches[0].pageX,
|
|
y: t.changedTouches[0].pageY,
|
|
type: "touch",
|
|
};
|
|
ft("touchRelease", t, e);
|
|
}
|
|
var c = -1;
|
|
if (0 === f)
|
|
if (((ue = false), n.unbind(window, w, i), Re(), ye)) c = 0;
|
|
else if (-1 !== se) c = ct() - se;
|
|
if (((se = 1 === f ? ct() : -1), -1 !== c && c < 150)) l = "zoom";
|
|
else l = "swipe";
|
|
if (ye && f < 2) {
|
|
if (((ye = false), 1 === f)) l = "zoomPointerUp";
|
|
ft("zoomGestureEnded");
|
|
}
|
|
if (((ge = null), ce || fe || Ae || ie)) {
|
|
if ((zt(), !Qt)) Qt = on();
|
|
if ((Qt.calculateSwipeSpeed("x"), !ie)) {
|
|
if ((ve || Ae) && 0 === f) {
|
|
var h;
|
|
if (sn(l, Qt)) return;
|
|
l = "zoomPointerUp";
|
|
}
|
|
if (!Ae) {
|
|
if ("swipe" !== l) return ln(), void 0;
|
|
if (!ve && S > i.currItem.fitRatio) an(Qt);
|
|
}
|
|
} else {
|
|
var p;
|
|
if (je() < s.verticalDragRange) i.close();
|
|
else {
|
|
var m = y.y,
|
|
v = Le;
|
|
Ut(
|
|
"verticalDrag",
|
|
0,
|
|
1,
|
|
300,
|
|
n.easing.cubic.out,
|
|
function (t) {
|
|
(y.y = (i.currItem.initialPosition.y - m) * t + m),
|
|
dt((1 - v) * t + v),
|
|
pt();
|
|
}
|
|
),
|
|
ft("onVerticalDrag", 1);
|
|
}
|
|
}
|
|
}
|
|
},
|
|
on = function () {
|
|
var t,
|
|
e,
|
|
i = {
|
|
lastFlickOffset: {},
|
|
lastFlickDist: {},
|
|
lastFlickSpeed: {},
|
|
slowDownRatio: {},
|
|
slowDownRatioReverse: {},
|
|
speedDecelerationRatio: {},
|
|
speedDecelerationRatioAbs: {},
|
|
distanceOffset: {},
|
|
backAnimDestination: {},
|
|
backAnimStarted: {},
|
|
calculateSwipeSpeed: function (n) {
|
|
if (te.length > 1)
|
|
(t = ct() - Yt + 50), (e = te[te.length - 2][n]);
|
|
else (t = ct() - Vt), (e = Xt[n]);
|
|
if (
|
|
((i.lastFlickOffset[n] = Zt[n] - e),
|
|
(i.lastFlickDist[n] = Math.abs(i.lastFlickOffset[n])),
|
|
i.lastFlickDist[n] > 20)
|
|
)
|
|
i.lastFlickSpeed[n] = i.lastFlickOffset[n] / t;
|
|
else i.lastFlickSpeed[n] = 0;
|
|
if (Math.abs(i.lastFlickSpeed[n]) < 0.1)
|
|
i.lastFlickSpeed[n] = 0;
|
|
(i.slowDownRatio[n] = 0.95),
|
|
(i.slowDownRatioReverse[n] = 1 - i.slowDownRatio[n]),
|
|
(i.speedDecelerationRatio[n] = 1);
|
|
},
|
|
calculateOverBoundsAnimOffset: function (t, e) {
|
|
if (!i.backAnimStarted[t]) {
|
|
if (y[t] > Ce.min[t]) i.backAnimDestination[t] = Ce.min[t];
|
|
else if (y[t] < Ce.max[t])
|
|
i.backAnimDestination[t] = Ce.max[t];
|
|
if (void 0 !== i.backAnimDestination[t])
|
|
if (
|
|
((i.slowDownRatio[t] = 0.7),
|
|
(i.slowDownRatioReverse[t] = 1 - i.slowDownRatio[t]),
|
|
i.speedDecelerationRatioAbs[t] < 0.05)
|
|
)
|
|
(i.lastFlickSpeed[t] = 0),
|
|
(i.backAnimStarted[t] = true),
|
|
Ut(
|
|
"bounceZoomPan" + t,
|
|
y[t],
|
|
i.backAnimDestination[t],
|
|
e || 300,
|
|
n.easing.sine.out,
|
|
function (e) {
|
|
(y[t] = e), pt();
|
|
}
|
|
);
|
|
}
|
|
},
|
|
calculateAnimOffset: function (t) {
|
|
if (!i.backAnimStarted[t])
|
|
(i.speedDecelerationRatio[t] =
|
|
i.speedDecelerationRatio[t] *
|
|
(i.slowDownRatio[t] +
|
|
i.slowDownRatioReverse[t] -
|
|
(i.slowDownRatioReverse[t] * i.timeDiff) / 10)),
|
|
(i.speedDecelerationRatioAbs[t] = Math.abs(
|
|
i.lastFlickSpeed[t] * i.speedDecelerationRatio[t]
|
|
)),
|
|
(i.distanceOffset[t] =
|
|
i.lastFlickSpeed[t] *
|
|
i.speedDecelerationRatio[t] *
|
|
i.timeDiff),
|
|
(y[t] += i.distanceOffset[t]);
|
|
},
|
|
panAnimLoop: function () {
|
|
if (Pt.zoomPan)
|
|
if (
|
|
((Pt.zoomPan.raf = j(i.panAnimLoop)),
|
|
(i.now = ct()),
|
|
(i.timeDiff = i.now - i.lastNow),
|
|
(i.lastNow = i.now),
|
|
i.calculateAnimOffset("x"),
|
|
i.calculateAnimOffset("y"),
|
|
pt(),
|
|
i.calculateOverBoundsAnimOffset("x"),
|
|
i.calculateOverBoundsAnimOffset("y"),
|
|
i.speedDecelerationRatioAbs.x < 0.05 &&
|
|
i.speedDecelerationRatioAbs.y < 0.05)
|
|
)
|
|
return (
|
|
(y.x = Math.round(y.x)),
|
|
(y.y = Math.round(y.y)),
|
|
pt(),
|
|
Rt("zoomPan"),
|
|
void 0
|
|
);
|
|
},
|
|
};
|
|
return i;
|
|
},
|
|
an = function (t) {
|
|
if (
|
|
(t.calculateSwipeSpeed("y"),
|
|
(Ce = i.currItem.bounds),
|
|
(t.backAnimDestination = {}),
|
|
(t.backAnimStarted = {}),
|
|
Math.abs(t.lastFlickSpeed.x) <= 0.05 &&
|
|
Math.abs(t.lastFlickSpeed.y) <= 0.05)
|
|
)
|
|
return (
|
|
(t.speedDecelerationRatioAbs.x = t.speedDecelerationRatioAbs.y =
|
|
0),
|
|
t.calculateOverBoundsAnimOffset("x"),
|
|
t.calculateOverBoundsAnimOffset("y"),
|
|
true
|
|
);
|
|
Nt("zoomPan"), (t.lastNow = ct()), t.panAnimLoop();
|
|
},
|
|
sn = function (t, e) {
|
|
var o, a, u;
|
|
if (!Ae) oe = h;
|
|
if ("swipe" === t) {
|
|
var l = Zt.x - Xt.x,
|
|
f = e.lastFlickDist.x < 10;
|
|
if (l > Ht && (f || e.lastFlickOffset.x > 20)) a = -1;
|
|
else if (l < -Ht && (f || e.lastFlickOffset.x < -20)) a = 1;
|
|
}
|
|
if (a) {
|
|
if ((h += a) < 0) (h = s.loop ? wn() - 1 : 0), (u = true);
|
|
else if (h >= wn()) (h = s.loop ? 0 : wn() - 1), (u = true);
|
|
if (!u || s.loop) (P += a), (k -= a), (o = true);
|
|
}
|
|
var c = L.x * k,
|
|
p = Math.abs(c - xe.x),
|
|
m;
|
|
if (!o && c > xe.x != e.lastFlickSpeed.x > 0) m = 333;
|
|
else
|
|
(m =
|
|
Math.abs(e.lastFlickSpeed.x) > 0
|
|
? p / Math.abs(e.lastFlickSpeed.x)
|
|
: 333),
|
|
(m = Math.min(m, 400)),
|
|
(m = Math.max(m, 250));
|
|
if (oe === h) o = false;
|
|
if (
|
|
((Ae = true),
|
|
ft("mainScrollAnimStart"),
|
|
Ut("mainScroll", xe.x, c, m, n.easing.cubic.out, gt, function () {
|
|
if ((zt(), (Ae = false), (oe = -1), o || oe !== h))
|
|
i.updateCurrItem();
|
|
ft("mainScrollAnimComplete");
|
|
}),
|
|
o)
|
|
)
|
|
i.updateCurrItem(true);
|
|
return o;
|
|
},
|
|
un = function (t) {
|
|
return (1 / be) * t * A;
|
|
},
|
|
ln = function () {
|
|
var t = S,
|
|
e = Tt(),
|
|
o = Dt();
|
|
if (S < e) t = e;
|
|
else if (S > o) t = o;
|
|
var a = 1,
|
|
s,
|
|
u = Le;
|
|
if (ke && !ne && !Be && S < e) return i.close(), true;
|
|
if (ke)
|
|
s = function (t) {
|
|
dt((a - u) * t + u);
|
|
};
|
|
return i.zoomTo(t, 0, 200, n.easing.cubic.out, s), true;
|
|
};
|
|
at("Gestures", {
|
|
publicMethods: {
|
|
initGestures: function () {
|
|
var t = function (t, e, move, n, i) {
|
|
if (((F = t + e), (N = t + move), (z = t + n), i)) U = t + i;
|
|
else U = "";
|
|
};
|
|
if (($ = tt.pointerEvent) && tt.touch) tt.touch = false;
|
|
if ($)
|
|
if (navigator.msPointerEnabled)
|
|
t("MSPointer", "Down", "Move", "Up", "Cancel");
|
|
else t("pointer", "down", "move", "up", "cancel");
|
|
else if (tt.touch)
|
|
t("touch", "start", "move", "end", "cancel"), (Y = true);
|
|
else t("mouse", "down", "move", "up");
|
|
if (((w = N + " " + z + " " + U), (b = F), $ && !Y))
|
|
Y =
|
|
navigator.maxTouchPoints > 1 ||
|
|
navigator.msMaxTouchPoints > 1;
|
|
if (
|
|
((i.likelyTouchDevice = Y),
|
|
(C[F] = tn),
|
|
(C[N] = en),
|
|
(C[z] = rn),
|
|
U)
|
|
)
|
|
C[U] = C[z];
|
|
if (tt.touch)
|
|
(b += " mousedown"),
|
|
(w += " mousemove mouseup"),
|
|
(C.mousedown = C[F]),
|
|
(C.mousemove = C[N]),
|
|
(C.mouseup = C[z]);
|
|
if (!Y) s.allowPanToNext = false;
|
|
},
|
|
},
|
|
});
|
|
var fn,
|
|
cn = function (t, e, o, a) {
|
|
if (fn) clearTimeout(fn);
|
|
var u;
|
|
if (((vn = true), (mn = true), t.initialLayout))
|
|
(u = t.initialLayout), (t.initialLayout = null);
|
|
else u = s.getThumbBoundsFn && s.getThumbBoundsFn(h);
|
|
var l = o ? s.hideAnimationDuration : s.showAnimationDuration,
|
|
f = function () {
|
|
if ((Rt("initialZoom"), !o)) {
|
|
if ((dt(1), e)) e.style.display = "block";
|
|
n.addClass(template, "pswp--animated-in"),
|
|
ft("initialZoom" + (o ? "OutEnd" : "InEnd"));
|
|
} else
|
|
i.template.removeAttribute("style"),
|
|
i.bg.removeAttribute("style");
|
|
if (a) a();
|
|
vn = false;
|
|
};
|
|
if (l && u && void 0 !== u.x) {
|
|
var p;
|
|
(function () {
|
|
var e = c,
|
|
a =
|
|
!i.currItem.src ||
|
|
i.currItem.loadError ||
|
|
s.showHideOpacity;
|
|
if (t.miniImg)
|
|
t.miniImg.style.webkitBackfaceVisibility = "hidden";
|
|
if (!o)
|
|
(S = u.w / t.w),
|
|
(y.x = u.x),
|
|
(y.y = u.y - X),
|
|
(i[a ? "template" : "bg"].style.opacity = 0.001),
|
|
pt();
|
|
if ((Nt("initialZoom"), o && !e))
|
|
n.removeClass(template, "pswp--animated-in");
|
|
if (a)
|
|
if (o)
|
|
n[(e ? "remove" : "add") + "Class"](
|
|
template,
|
|
"pswp--animate_opacity"
|
|
);
|
|
else
|
|
setTimeout(function () {
|
|
n.addClass(template, "pswp--animate_opacity");
|
|
}, 30);
|
|
fn = setTimeout(
|
|
function () {
|
|
if ((ft("initialZoom" + (o ? "Out" : "In")), !o)) {
|
|
if (
|
|
((S = t.initialZoomLevel),
|
|
wt(y, t.initialPosition),
|
|
pt(),
|
|
dt(1),
|
|
a)
|
|
)
|
|
template.style.opacity = 1;
|
|
else dt(1);
|
|
fn = setTimeout(f, l + 20);
|
|
} else {
|
|
var i = u.w / t.w,
|
|
s = { x: y.x, y: y.y },
|
|
c = S,
|
|
h = Le,
|
|
p = function (t) {
|
|
if (1 === t) (S = i), (y.x = u.x), (y.y = u.y - J);
|
|
else
|
|
(S = (i - c) * t + c),
|
|
(y.x = (u.x - s.x) * t + s.x),
|
|
(y.y = (u.y - J - s.y) * t + s.y);
|
|
if ((pt(), a)) template.style.opacity = 1 - t;
|
|
else dt(h - t * h);
|
|
};
|
|
if (e)
|
|
Ut("initialZoom", 0, 1, l, n.easing.cubic.out, p, f);
|
|
else p(1), (fn = setTimeout(f, l + 20));
|
|
}
|
|
},
|
|
o ? 25 : 90
|
|
);
|
|
})();
|
|
} else if (
|
|
(ft("initialZoom" + (o ? "Out" : "In")),
|
|
(S = t.initialZoomLevel),
|
|
wt(y, t.initialPosition),
|
|
pt(),
|
|
(template.style.opacity = o ? 0 : 1),
|
|
dt(1),
|
|
l)
|
|
)
|
|
setTimeout(function () {
|
|
f();
|
|
}, l);
|
|
else f();
|
|
},
|
|
dn,
|
|
hn = {},
|
|
pn = [],
|
|
mn,
|
|
vn,
|
|
gn = {
|
|
index: 0,
|
|
errorMsg:
|
|
'<div class="pswp__error-msg"><a href="%url%" target="_blank">The image</a> could not be loaded.</div>',
|
|
forceProgressiveLoading: false,
|
|
preload: [1, 1],
|
|
getNumItemsFn: function () {
|
|
return dn.length;
|
|
},
|
|
},
|
|
yn,
|
|
wn,
|
|
bn,
|
|
Cn = function () {
|
|
return {
|
|
center: { x: 0, y: 0 },
|
|
max: { x: 0, y: 0 },
|
|
min: { x: 0, y: 0 },
|
|
};
|
|
},
|
|
xn = function (t, e, n) {
|
|
var i = t.bounds;
|
|
(i.center.x = Math.round((hn.x - e) / 2)),
|
|
(i.center.y = Math.round((hn.y - n) / 2) + t.vGap.top),
|
|
(i.max.x = e > hn.x ? Math.round(hn.x - e) : i.center.x),
|
|
(i.max.y =
|
|
n > hn.y ? Math.round(hn.y - n) + t.vGap.top : i.center.y),
|
|
(i.min.x = e > hn.x ? 0 : i.center.x),
|
|
(i.min.y = n > hn.y ? t.vGap.top : i.center.y);
|
|
},
|
|
Sn = function (t, e, n) {
|
|
if (t.src && !t.loadError) {
|
|
var i = !n;
|
|
if (i) {
|
|
if (!t.vGap) t.vGap = { top: 0, bottom: 0 };
|
|
ft("parseVerticalMargin", t);
|
|
}
|
|
if (
|
|
((hn.x = e.x), (hn.y = e.y - t.vGap.top - t.vGap.bottom), i)
|
|
) {
|
|
var o = hn.x / t.w,
|
|
a = hn.y / t.h;
|
|
t.fitRatio = o < a ? o : a;
|
|
var u = s.scaleMode;
|
|
if ("orig" === u) n = 1;
|
|
else if ("fit" === u) n = t.fitRatio;
|
|
if (n > 1) n = 1;
|
|
if (((t.initialZoomLevel = n), !t.bounds))
|
|
t.bounds = {
|
|
center: { x: 0, y: 0 },
|
|
max: { x: 0, y: 0 },
|
|
min: { x: 0, y: 0 },
|
|
};
|
|
}
|
|
if (!n) return;
|
|
if ((xn(t, t.w * n, t.h * n), i && n === t.initialZoomLevel))
|
|
t.initialPosition = t.bounds.center;
|
|
return t.bounds;
|
|
} else
|
|
return (
|
|
(t.w = t.h = 0),
|
|
(t.initialZoomLevel = t.fitRatio = 1),
|
|
(t.bounds = {
|
|
center: { x: 0, y: 0 },
|
|
max: { x: 0, y: 0 },
|
|
min: { x: 0, y: 0 },
|
|
}),
|
|
(t.initialPosition = t.bounds.center),
|
|
t.bounds
|
|
);
|
|
},
|
|
An = function (index, t, e, n, o, a) {
|
|
if (!t.loadError)
|
|
if (n)
|
|
if (
|
|
((t.imageAppended = true),
|
|
In(t, n, t === i.currItem && rt),
|
|
e.appendChild(n),
|
|
a)
|
|
)
|
|
setTimeout(function () {
|
|
if (t && t.loaded && t.placeholder)
|
|
(t.placeholder.style.display = "none"),
|
|
(t.placeholder = null);
|
|
}, 500);
|
|
},
|
|
_n = function (t) {
|
|
(t.loading = true), (t.loaded = false);
|
|
var e = (t.img = n.createEl("pswp__img", "img")),
|
|
i = function () {
|
|
if (((t.loading = false), (t.loaded = true), t.loadComplete))
|
|
t.loadComplete(t);
|
|
else t.img = null;
|
|
(e.onload = e.onerror = null), (e = null);
|
|
};
|
|
return (
|
|
(e.onload = i),
|
|
(e.onerror = function () {
|
|
(t.loadError = true), i();
|
|
}),
|
|
(e.src = t.src),
|
|
e
|
|
);
|
|
},
|
|
Tn = function (t, e) {
|
|
if (t.src && t.loadError && t.container) {
|
|
if (e) t.container.innerHTML = "";
|
|
return (
|
|
(t.container.innerHTML = s.errorMsg.replace("%url%", t.src)),
|
|
true
|
|
);
|
|
}
|
|
},
|
|
In = function (t, e, n) {
|
|
if (t.src) {
|
|
if (!e) e = t.container.lastChild;
|
|
var i = n ? t.w : Math.round(t.w * t.fitRatio),
|
|
o = n ? t.h : Math.round(t.h * t.fitRatio);
|
|
if (t.placeholder && !t.loaded)
|
|
(t.placeholder.style.width = i + "px"),
|
|
(t.placeholder.style.height = o + "px");
|
|
(e.style.width = i + "px"), (e.style.height = o + "px");
|
|
}
|
|
},
|
|
En = function () {
|
|
if (pn.length) {
|
|
for (var t, e = 0; e < pn.length; e++)
|
|
if ((t = pn[e]).holder.index === t.index)
|
|
An(
|
|
t.index,
|
|
t.item,
|
|
t.baseDiv,
|
|
t.img,
|
|
false,
|
|
t.clearPlaceholder
|
|
);
|
|
pn = [];
|
|
}
|
|
};
|
|
at("Controller", {
|
|
publicMethods: {
|
|
lazyLoadItem: function (index) {
|
|
index = st(index);
|
|
var t = yn(index);
|
|
if (t && ((!t.loaded && !t.loading) || E))
|
|
if ((ft("gettingData", index, t), t.src)) _n(t);
|
|
},
|
|
initController: function () {
|
|
if (
|
|
(n.extend(s, gn, true),
|
|
(i.items = dn = items),
|
|
(yn = i.getItemAt),
|
|
(wn = s.getNumItemsFn),
|
|
(bn = s.loop),
|
|
wn() < 3)
|
|
)
|
|
s.loop = false;
|
|
lt("beforeChange", function (diff) {
|
|
var t = s.preload,
|
|
e = null === diff ? true : diff >= 0,
|
|
n = Math.min(t[0], wn()),
|
|
o = Math.min(t[1], wn()),
|
|
a;
|
|
for (a = 1; a <= (e ? o : n); a++) i.lazyLoadItem(h + a);
|
|
for (a = 1; a <= (e ? n : o); a++) i.lazyLoadItem(h - a);
|
|
}),
|
|
lt("initialLayout", function () {
|
|
i.currItem.initialLayout =
|
|
s.getThumbBoundsFn && s.getThumbBoundsFn(h);
|
|
}),
|
|
lt("mainScrollAnimComplete", En),
|
|
lt("initialZoomInEnd", En),
|
|
lt("destroy", function () {
|
|
for (var t, e = 0; e < dn.length; e++) {
|
|
if ((t = dn[e]).container) t.container = null;
|
|
if (t.placeholder) t.placeholder = null;
|
|
if (t.img) t.img = null;
|
|
if (t.preloader) t.preloader = null;
|
|
if (t.loadError) t.loaded = t.loadError = false;
|
|
}
|
|
pn = null;
|
|
});
|
|
},
|
|
getItemAt: function (index) {
|
|
if (index >= 0) return void 0 !== dn[index] ? dn[index] : false;
|
|
else return false;
|
|
},
|
|
allowProgressiveImg: function () {
|
|
return (
|
|
s.forceProgressiveLoading ||
|
|
!Y ||
|
|
s.mouseUsed ||
|
|
screen.width > 1200
|
|
);
|
|
},
|
|
setContent: function (t, index) {
|
|
if (s.loop) index = st(index);
|
|
var e = i.getItemAt(t.index);
|
|
if (e) e.container = null;
|
|
var o = i.getItemAt(index),
|
|
a;
|
|
if (!o) return (t.el.innerHTML = ""), void 0;
|
|
ft("gettingData", index, o), (t.index = index), (t.item = o);
|
|
var u = (o.container = n.createEl("pswp__zoom-wrap"));
|
|
if (!o.src && o.html)
|
|
if (o.html.tagName) u.appendChild(o.html);
|
|
else u.innerHTML = o.html;
|
|
if ((Tn(o), Sn(o, x), o.src && !o.loadError && !o.loaded)) {
|
|
if (
|
|
((o.loadComplete = function (e) {
|
|
if (l) {
|
|
if (t && t.index === index) {
|
|
if (Tn(e, true)) {
|
|
if (
|
|
((e.loadComplete = e.img = null),
|
|
Sn(e, x),
|
|
mt(e),
|
|
t.index === h)
|
|
)
|
|
i.updateCurrZoomItem();
|
|
return;
|
|
}
|
|
if (!e.imageAppended)
|
|
if (tt.transform && (Ae || vn))
|
|
pn.push({
|
|
item: e,
|
|
baseDiv: u,
|
|
img: e.img,
|
|
index: index,
|
|
holder: t,
|
|
clearPlaceholder: true,
|
|
});
|
|
else An(index, e, u, e.img, Ae || vn, true);
|
|
else if (!vn && e.placeholder)
|
|
(e.placeholder.style.display = "none"),
|
|
(e.placeholder = null);
|
|
}
|
|
(e.loadComplete = null),
|
|
(e.img = null),
|
|
ft("imageLoadComplete", index, e);
|
|
}
|
|
}),
|
|
n.features.transform)
|
|
) {
|
|
var f = "pswp__img pswp__img--placeholder";
|
|
f += o.msrc ? "" : " pswp__img--placeholder--blank";
|
|
var placeholder = n.createEl(f, o.msrc ? "img" : "");
|
|
if (o.msrc) placeholder.src = o.msrc;
|
|
In(o, placeholder),
|
|
u.appendChild(placeholder),
|
|
(o.placeholder = placeholder);
|
|
}
|
|
if (!o.loading) _n(o);
|
|
if (i.allowProgressiveImg())
|
|
if (!mn && tt.transform)
|
|
pn.push({
|
|
item: o,
|
|
baseDiv: u,
|
|
img: o.img,
|
|
index: index,
|
|
holder: t,
|
|
});
|
|
else An(index, o, u, o.img, true, true);
|
|
} else if (o.src && !o.loadError)
|
|
((a = n.createEl("pswp__img", "img")).style.opacity = 1),
|
|
(a.src = o.src),
|
|
In(o, a),
|
|
An(index, o, u, a, true);
|
|
if (!mn && index === h) (Se = u.style), cn(o, a || o.img);
|
|
else mt(o);
|
|
(t.el.innerHTML = ""), t.el.appendChild(u);
|
|
},
|
|
cleanSlide: function (t) {
|
|
if (t.img) t.img.onload = t.img.onerror = null;
|
|
t.loaded = t.loading = t.img = t.imageAppended = false;
|
|
},
|
|
},
|
|
});
|
|
var Dn,
|
|
kn = {},
|
|
Mn = function (t, e, n) {
|
|
var i = document.createEvent("CustomEvent"),
|
|
o = {
|
|
origEvent: t,
|
|
target: t.target,
|
|
releasePoint: e,
|
|
pointerType: n || "touch",
|
|
};
|
|
i.initCustomEvent("pswpTap", true, true, o),
|
|
t.target.dispatchEvent(i);
|
|
},
|
|
Ln;
|
|
at("Tap", {
|
|
publicMethods: {
|
|
initTap: function () {
|
|
lt("firstTouchStart", i.onTapStart),
|
|
lt("touchRelease", i.onTapRelease),
|
|
lt("destroy", function () {
|
|
(kn = {}), (Dn = null);
|
|
});
|
|
},
|
|
onTapStart: function (t) {
|
|
if (t.length > 1) clearTimeout(Dn), (Dn = null);
|
|
},
|
|
onTapRelease: function (t, e) {
|
|
if (e)
|
|
if (!ce && !le && !Ft) {
|
|
var i = e,
|
|
o;
|
|
if (Dn)
|
|
if ((clearTimeout(Dn), (Dn = null), Pe(i, kn)))
|
|
return ft("doubleTap", i), void 0;
|
|
if ("mouse" === e.type) return Mn(t, e, "mouse"), void 0;
|
|
if (
|
|
"BUTTON" === t.target.tagName.toUpperCase() ||
|
|
n.hasClass(t.target, "pswp__single-tap")
|
|
)
|
|
return Mn(t, e), void 0;
|
|
wt(kn, i),
|
|
(Dn = setTimeout(function () {
|
|
Mn(t, e), (Dn = null);
|
|
}, 300));
|
|
}
|
|
},
|
|
},
|
|
}),
|
|
at("DesktopZoom", {
|
|
publicMethods: {
|
|
initDesktopZoom: function () {
|
|
if (!K)
|
|
if (Y)
|
|
lt("mouseUsed", function () {
|
|
i.setupDesktopZoom();
|
|
});
|
|
else i.setupDesktopZoom(true);
|
|
},
|
|
setupDesktopZoom: function (t) {
|
|
Ln = {};
|
|
var events = "wheel mousewheel DOMMouseScroll";
|
|
lt("bindEvents", function () {
|
|
n.bind(template, events, i.handleMouseWheel);
|
|
}),
|
|
lt("unbindEvents", function () {
|
|
if (Ln) n.unbind(template, events, i.handleMouseWheel);
|
|
}),
|
|
(i.mouseZoomedIn = false);
|
|
var e,
|
|
o = function () {
|
|
if (i.mouseZoomedIn)
|
|
n.removeClass(template, "pswp--zoomed-in"),
|
|
(i.mouseZoomedIn = false);
|
|
if (S < 1) n.addClass(template, "pswp--zoom-allowed");
|
|
else n.removeClass(template, "pswp--zoom-allowed");
|
|
a();
|
|
},
|
|
a = function () {
|
|
if (e)
|
|
n.removeClass(template, "pswp--dragging"), (e = false);
|
|
};
|
|
if (
|
|
(lt("resize", o),
|
|
lt("afterChange", o),
|
|
lt("pointerDown", function () {
|
|
if (i.mouseZoomedIn)
|
|
(e = true), n.addClass(template, "pswp--dragging");
|
|
}),
|
|
lt("pointerUp", a),
|
|
!t)
|
|
)
|
|
o();
|
|
},
|
|
handleMouseWheel: function (t) {
|
|
if (S <= i.currItem.fitRatio) {
|
|
if (s.modal)
|
|
if (!s.closeOnScroll || Ft || ue) t.preventDefault();
|
|
else if (H && Math.abs(t.deltaY) > 2) (c = true), i.close();
|
|
return true;
|
|
}
|
|
if ((t.stopPropagation(), (Ln.x = 0), "deltaX" in t))
|
|
if (1 === t.deltaMode)
|
|
(Ln.x = 18 * t.deltaX), (Ln.y = 18 * t.deltaY);
|
|
else (Ln.x = t.deltaX), (Ln.y = t.deltaY);
|
|
else if ("wheelDelta" in t) {
|
|
if (t.wheelDeltaX) Ln.x = -0.16 * t.wheelDeltaX;
|
|
if (t.wheelDeltaY) Ln.y = -0.16 * t.wheelDeltaY;
|
|
else Ln.y = -0.16 * t.wheelDelta;
|
|
} else if ("detail" in t) Ln.y = t.detail;
|
|
else return;
|
|
_t(S, true);
|
|
var e = y.x - Ln.x,
|
|
n = y.y - Ln.y;
|
|
if (
|
|
s.modal ||
|
|
(e <= Ce.min.x &&
|
|
e >= Ce.max.x &&
|
|
n <= Ce.min.y &&
|
|
n >= Ce.max.y)
|
|
)
|
|
t.preventDefault();
|
|
i.panTo(e, n);
|
|
},
|
|
toggleDesktopZoom: function (t) {
|
|
t = t || { x: x.x / 2 + M.x, y: x.y / 2 + M.y };
|
|
var e = s.getDoubleTapZoom(true, i.currItem),
|
|
o = S === e;
|
|
(i.mouseZoomedIn = !o),
|
|
i.zoomTo(o ? i.currItem.initialZoomLevel : e, t, 333),
|
|
n[(!o ? "add" : "remove") + "Class"](
|
|
template,
|
|
"pswp--zoomed-in"
|
|
);
|
|
},
|
|
},
|
|
});
|
|
var Bn = { history: true, galleryUID: 1 },
|
|
On,
|
|
Pn,
|
|
Fn,
|
|
Rn,
|
|
Nn,
|
|
zn,
|
|
Un,
|
|
qn,
|
|
Hn,
|
|
$n,
|
|
Vn,
|
|
Yn,
|
|
Wn = function () {
|
|
return Vn.hash.substring(1);
|
|
},
|
|
jn = function () {
|
|
if (On) clearTimeout(On);
|
|
if (Fn) clearTimeout(Fn);
|
|
},
|
|
Gn = function () {
|
|
var hash = Wn(),
|
|
t = {};
|
|
if (hash.length < 5) return t;
|
|
var e,
|
|
n = hash.split("&");
|
|
for (e = 0; e < n.length; e++)
|
|
if (n[e]) {
|
|
var i = n[e].split("=");
|
|
if (!(i.length < 2)) t[i[0]] = i[1];
|
|
}
|
|
if (s.galleryPIDs) {
|
|
var o = t.pid;
|
|
for (t.pid = 0, e = 0; e < dn.length; e++)
|
|
if (dn[e].pid === o) {
|
|
t.pid = e;
|
|
break;
|
|
}
|
|
} else t.pid = parseInt(t.pid, 10) - 1;
|
|
if (t.pid < 0) t.pid = 0;
|
|
return t;
|
|
},
|
|
Zn = function () {
|
|
if (Fn) clearTimeout(Fn);
|
|
if (Ft || ue) return (Fn = setTimeout(Zn, 500)), void 0;
|
|
if (Rn) clearTimeout(Pn);
|
|
else Rn = true;
|
|
var t = h + 1,
|
|
e = yn(h);
|
|
if (e.hasOwnProperty("pid")) t = e.pid;
|
|
var n = Un + "&" + "gid=" + s.galleryUID + "&" + "pid=" + t;
|
|
if (!qn) if (-1 === Vn.hash.indexOf(n)) $n = true;
|
|
var i = Vn.href.split("#")[0] + "#" + n;
|
|
if (Yn) {
|
|
if ("#" + n !== window.location.hash)
|
|
history[qn ? "replaceState" : "pushState"](
|
|
"",
|
|
document.title,
|
|
i
|
|
);
|
|
} else if (qn) Vn.replace(i);
|
|
else Vn.hash = n;
|
|
(qn = true),
|
|
(Pn = setTimeout(function () {
|
|
Rn = false;
|
|
}, 60));
|
|
};
|
|
at("History", {
|
|
publicMethods: {
|
|
initHistory: function () {
|
|
if ((n.extend(s, Bn, true), s.history)) {
|
|
if (
|
|
((Vn = window.location),
|
|
($n = false),
|
|
(Hn = false),
|
|
(qn = false),
|
|
(Un = Wn()),
|
|
(Yn = "pushState" in history),
|
|
Un.indexOf("gid=") > -1)
|
|
)
|
|
Un = (Un = Un.split("&gid=")[0]).split("?gid=")[0];
|
|
lt("afterChange", i.updateURL),
|
|
lt("unbindEvents", function () {
|
|
n.unbind(window, "hashchange", i.onHashChange);
|
|
});
|
|
var t = function () {
|
|
if (((zn = true), !Hn))
|
|
if ($n) history.back();
|
|
else if (Un) Vn.hash = Un;
|
|
else if (Yn)
|
|
history.pushState(
|
|
"",
|
|
document.title,
|
|
Vn.pathname + Vn.search
|
|
);
|
|
else Vn.hash = "";
|
|
jn();
|
|
};
|
|
lt("unbindEvents", function () {
|
|
if (c) t();
|
|
}),
|
|
lt("destroy", function () {
|
|
if (!zn) t();
|
|
}),
|
|
lt("firstUpdate", function () {
|
|
h = Gn().pid;
|
|
});
|
|
var index = Un.indexOf("pid=");
|
|
if (index > -1)
|
|
if ("&" === (Un = Un.substring(0, index)).slice(-1))
|
|
Un = Un.slice(0, -1);
|
|
setTimeout(function () {
|
|
if (l) n.bind(window, "hashchange", i.onHashChange);
|
|
}, 40);
|
|
}
|
|
},
|
|
onHashChange: function () {
|
|
if (Wn() === Un) return (Hn = true), i.close(), void 0;
|
|
if (!Rn) (Nn = true), i.goTo(Gn().pid), (Nn = false);
|
|
},
|
|
updateURL: function () {
|
|
if ((jn(), !Nn))
|
|
if (!qn) Zn();
|
|
else On = setTimeout(Zn, 800);
|
|
},
|
|
},
|
|
}),
|
|
n.extend(i, qt);
|
|
};
|
|
return t;
|
|
});
|
|
},
|
|
9815: function (t, e, n) {
|
|
"use strict";
|
|
var i, o;
|
|
/*! PhotoSwipe Default UI - 4.1.3 - 2019-01-08
|
|
* http://photoswipe.com
|
|
* Copyright (c) 2019 Dmitry Semenov; */ !(function (a, factory) {
|
|
if (true)
|
|
!(
|
|
void 0 !==
|
|
(o = "function" == typeof (i = factory) ? i.call(e, n, e, t) : i) &&
|
|
(t.exports = o)
|
|
);
|
|
else if ("object" == typeof e) t.exports = factory();
|
|
else a.PhotoSwipeUI_Default = factory();
|
|
})(this, function () {
|
|
var t;
|
|
return function (t, e) {
|
|
var n = this,
|
|
i = false,
|
|
o = true,
|
|
a,
|
|
s,
|
|
u,
|
|
l,
|
|
f,
|
|
c,
|
|
h,
|
|
p = true,
|
|
m,
|
|
v,
|
|
g,
|
|
y,
|
|
w,
|
|
b,
|
|
C,
|
|
x,
|
|
S = {
|
|
barsSize: { top: 44, bottom: "auto" },
|
|
closeElClasses: ["item", "caption", "zoom-wrap", "ui", "top-bar"],
|
|
timeToIdle: 4e3,
|
|
timeToIdleOutside: 1e3,
|
|
loadingIndicatorDelay: 1e3,
|
|
addCaptionHTMLFn: function (t, e) {
|
|
if (!t.title) return (e.children[0].innerHTML = ""), false;
|
|
else return (e.children[0].innerHTML = t.title), true;
|
|
},
|
|
closeEl: true,
|
|
captionEl: true,
|
|
fullscreenEl: true,
|
|
zoomEl: true,
|
|
shareEl: true,
|
|
counterEl: true,
|
|
arrowEl: true,
|
|
preloaderEl: true,
|
|
tapToClose: false,
|
|
tapToToggleControls: true,
|
|
clickToCloseNonZoomable: true,
|
|
shareButtons: [
|
|
{
|
|
id: "facebook",
|
|
label: "Share on Facebook",
|
|
url: "https://www.facebook.com/sharer/sharer.php?u={{url}}",
|
|
},
|
|
{
|
|
id: "twitter",
|
|
label: "Tweet",
|
|
url: "https://twitter.com/intent/tweet?text={{text}}&url={{url}}",
|
|
},
|
|
{
|
|
id: "pinterest",
|
|
label: "Pin it",
|
|
url:
|
|
"http://www.pinterest.com/pin/create/button/" +
|
|
"?url={{url}}&media={{image_url}}&description={{text}}",
|
|
},
|
|
{
|
|
id: "download",
|
|
label: "Download image",
|
|
url: "{{raw_image_url}}",
|
|
download: true,
|
|
},
|
|
],
|
|
getImageURLForShare: function () {
|
|
return t.currItem.src || "";
|
|
},
|
|
getPageURLForShare: function () {
|
|
return window.location.href;
|
|
},
|
|
getTextForShare: function () {
|
|
return t.currItem.title || "";
|
|
},
|
|
indexIndicatorSep: " / ",
|
|
fitControlsWidth: 1200,
|
|
},
|
|
A,
|
|
_,
|
|
T = function (t) {
|
|
if (A) return true;
|
|
if (((t = t || window.event), x.timeToIdle && x.mouseUsed && !v))
|
|
U();
|
|
for (
|
|
var n,
|
|
i,
|
|
o = (t.target || t.srcElement).getAttribute("class") || "",
|
|
a,
|
|
s = 0;
|
|
s < Z.length;
|
|
s++
|
|
)
|
|
if ((i = Z[s]).onTap && o.indexOf("pswp__" + i.name) > -1)
|
|
i.onTap(), (a = true);
|
|
if (a) {
|
|
if (t.stopPropagation) t.stopPropagation();
|
|
A = true;
|
|
var u = e.features.isOldAndroid ? 600 : 30;
|
|
_ = setTimeout(function () {
|
|
A = false;
|
|
}, u);
|
|
}
|
|
},
|
|
I = function () {
|
|
return (
|
|
!t.likelyTouchDevice ||
|
|
x.mouseUsed ||
|
|
screen.width > x.fitControlsWidth
|
|
);
|
|
},
|
|
E = function (el, t, add) {
|
|
e[(add ? "add" : "remove") + "Class"](el, "pswp__" + t);
|
|
},
|
|
k = function () {
|
|
var t = 1 === x.getNumItemsFn();
|
|
if (t !== C) E(s, "ui--one-slide", t), (C = t);
|
|
},
|
|
M = function () {
|
|
E(h, "share-modal--hidden", p);
|
|
},
|
|
L = function () {
|
|
if (!(p = !p))
|
|
M(),
|
|
setTimeout(function () {
|
|
if (!p) e.addClass(h, "pswp__share-modal--fade-in");
|
|
}, 30);
|
|
else
|
|
e.removeClass(h, "pswp__share-modal--fade-in"),
|
|
setTimeout(function () {
|
|
if (p) M();
|
|
}, 300);
|
|
if (!p) O();
|
|
return false;
|
|
},
|
|
B = function (e) {
|
|
var n = (e = e || window.event).target || e.srcElement;
|
|
if ((t.shout("shareLinkClick", e, n), !n.href)) return false;
|
|
if (n.hasAttribute("download")) return true;
|
|
if (
|
|
(window.open(
|
|
n.href,
|
|
"pswp_share",
|
|
"scrollbars=yes,resizable=yes,toolbar=no," +
|
|
"location=yes,width=550,height=420,top=100,left=" +
|
|
(window.screen ? Math.round(screen.width / 2 - 275) : 100)
|
|
),
|
|
!p)
|
|
)
|
|
L();
|
|
return false;
|
|
},
|
|
O = function () {
|
|
for (
|
|
var t = "", e, n, i, o, a, s = 0;
|
|
s < x.shareButtons.length;
|
|
s++
|
|
)
|
|
if (
|
|
((e = x.shareButtons[s]),
|
|
(i = x.getImageURLForShare(e)),
|
|
(o = x.getPageURLForShare(e)),
|
|
(a = x.getTextForShare(e)),
|
|
(t +=
|
|
'<a href="' +
|
|
(n = e.url
|
|
.replace("{{url}}", encodeURIComponent(o))
|
|
.replace("{{image_url}}", encodeURIComponent(i))
|
|
.replace("{{raw_image_url}}", i)
|
|
.replace("{{text}}", encodeURIComponent(a))) +
|
|
'" target="_blank" ' +
|
|
'class="pswp__share--' +
|
|
e.id +
|
|
'"' +
|
|
(e.download ? "download" : "") +
|
|
">" +
|
|
e.label +
|
|
"</a>"),
|
|
x.parseShareButtonOut)
|
|
)
|
|
t = x.parseShareButtonOut(e, t);
|
|
(h.children[0].innerHTML = t), (h.children[0].onclick = B);
|
|
},
|
|
P = function (t) {
|
|
for (var n = 0; n < x.closeElClasses.length; n++)
|
|
if (e.hasClass(t, "pswp__" + x.closeElClasses[n])) return true;
|
|
},
|
|
F,
|
|
N,
|
|
z = 0,
|
|
U = function () {
|
|
if ((clearTimeout(N), (z = 0), v)) n.setIdle(false);
|
|
},
|
|
H = function (t) {
|
|
var e = (t = t ? t : window.event).relatedTarget || t.toElement;
|
|
if (!e || "HTML" === e.nodeName)
|
|
clearTimeout(N),
|
|
(N = setTimeout(function () {
|
|
n.setIdle(true);
|
|
}, x.timeToIdleOutside));
|
|
},
|
|
$ = function () {
|
|
if (x.fullscreenEl && !e.features.isOldAndroid) {
|
|
if (!a) a = n.getFullscreenAPI();
|
|
if (a)
|
|
e.bind(document, a.eventK, n.updateFullscreen),
|
|
n.updateFullscreen(),
|
|
e.addClass(t.template, "pswp--supports-fs");
|
|
else e.removeClass(t.template, "pswp--supports-fs");
|
|
}
|
|
},
|
|
V = function () {
|
|
if (x.preloaderEl)
|
|
Y(true),
|
|
g("beforeChange", function () {
|
|
clearTimeout(b),
|
|
(b = setTimeout(function () {
|
|
if (t.currItem && t.currItem.loading) {
|
|
if (
|
|
!t.allowProgressiveImg() ||
|
|
(t.currItem.img && !t.currItem.img.naturalWidth)
|
|
)
|
|
Y(false);
|
|
} else Y(true);
|
|
}, x.loadingIndicatorDelay));
|
|
}),
|
|
g("imageLoadComplete", function (index, e) {
|
|
if (t.currItem === e) Y(true);
|
|
});
|
|
},
|
|
Y = function (t) {
|
|
if (w !== t) E(y, "preloader--active", !t), (w = t);
|
|
},
|
|
W = function (t) {
|
|
var n = t.vGap;
|
|
if (I()) {
|
|
var i = x.barsSize;
|
|
if (x.captionEl && "auto" === i.bottom) {
|
|
if (!l)
|
|
(l = e.createEl(
|
|
"pswp__caption pswp__caption--fake"
|
|
)).appendChild(e.createEl("pswp__caption__center")),
|
|
s.insertBefore(l, u),
|
|
e.addClass(s, "pswp__ui--fit");
|
|
if (x.addCaptionHTMLFn(t, l, true)) {
|
|
var o = l.clientHeight;
|
|
n.bottom = parseInt(o, 10) || 44;
|
|
} else n.bottom = i.top;
|
|
} else n.bottom = "auto" === i.bottom ? 0 : i.bottom;
|
|
n.top = i.top;
|
|
} else n.top = n.bottom = 0;
|
|
},
|
|
j = function () {
|
|
if (x.timeToIdle)
|
|
g("mouseUsed", function () {
|
|
e.bind(document, "mousemove", U),
|
|
e.bind(document, "mouseout", H),
|
|
(F = setInterval(function () {
|
|
if (2 === ++z) n.setIdle(true);
|
|
}, x.timeToIdle / 2));
|
|
});
|
|
},
|
|
G = function () {
|
|
var t;
|
|
g("onVerticalDrag", function (t) {
|
|
if (o && t < 0.95) n.hideControls();
|
|
else if (!o && t >= 0.95) n.showControls();
|
|
}),
|
|
g("onPinchClose", function (e) {
|
|
if (o && e < 0.9) n.hideControls(), (t = true);
|
|
else if (t && !o && e > 0.9) n.showControls();
|
|
}),
|
|
g("zoomGestureEnded", function () {
|
|
if ((t = false) && !o) n.showControls();
|
|
});
|
|
},
|
|
Z = [
|
|
{
|
|
name: "caption",
|
|
option: "captionEl",
|
|
onInit: function (el) {
|
|
u = el;
|
|
},
|
|
},
|
|
{
|
|
name: "share-modal",
|
|
option: "shareEl",
|
|
onInit: function (el) {
|
|
h = el;
|
|
},
|
|
onTap: function () {
|
|
L();
|
|
},
|
|
},
|
|
{
|
|
name: "button--share",
|
|
option: "shareEl",
|
|
onInit: function (el) {
|
|
c = el;
|
|
},
|
|
onTap: function () {
|
|
L();
|
|
},
|
|
},
|
|
{
|
|
name: "button--zoom",
|
|
option: "zoomEl",
|
|
onTap: t.toggleDesktopZoom,
|
|
},
|
|
{
|
|
name: "counter",
|
|
option: "counterEl",
|
|
onInit: function (el) {
|
|
f = el;
|
|
},
|
|
},
|
|
{ name: "button--close", option: "closeEl", onTap: t.close },
|
|
{ name: "button--arrow--left", option: "arrowEl", onTap: t.prev },
|
|
{ name: "button--arrow--right", option: "arrowEl", onTap: t.next },
|
|
{
|
|
name: "button--fs",
|
|
option: "fullscreenEl",
|
|
onTap: function () {
|
|
if (a.isFullscreen()) a.exit();
|
|
else a.enter();
|
|
},
|
|
},
|
|
{
|
|
name: "preloader",
|
|
option: "preloaderEl",
|
|
onInit: function (el) {
|
|
y = el;
|
|
},
|
|
},
|
|
],
|
|
X = function () {
|
|
var t,
|
|
n,
|
|
i,
|
|
o = function (o) {
|
|
if (o)
|
|
for (var a = o.length, s = 0; s < a; s++) {
|
|
(t = o[s]), (n = t.className);
|
|
for (var u = 0; u < Z.length; u++)
|
|
if (((i = Z[u]), n.indexOf("pswp__" + i.name) > -1))
|
|
if (x[i.option]) {
|
|
if (
|
|
(e.removeClass(t, "pswp__element--disabled"),
|
|
i.onInit)
|
|
)
|
|
i.onInit(t);
|
|
} else e.addClass(t, "pswp__element--disabled");
|
|
}
|
|
};
|
|
o(s.children);
|
|
var a = e.getChildByClass(s, "pswp__top-bar");
|
|
if (a) o(a.children);
|
|
};
|
|
(n.init = function () {
|
|
if (
|
|
(e.extend(t.options, S, true),
|
|
(x = t.options),
|
|
(s = e.getChildByClass(t.scrollWrap, "pswp__ui")),
|
|
(g = t.listen),
|
|
G(),
|
|
g("beforeChange", n.update),
|
|
g("doubleTap", function (e) {
|
|
var n = t.currItem.initialZoomLevel;
|
|
if (t.getZoomLevel() !== n) t.zoomTo(n, e, 333);
|
|
else t.zoomTo(x.getDoubleTapZoom(false, t.currItem), e, 333);
|
|
}),
|
|
g("preventDragEvent", function (t, e, n) {
|
|
var i = t.target || t.srcElement;
|
|
if (
|
|
i &&
|
|
i.getAttribute("class") &&
|
|
t.type.indexOf("mouse") > -1 &&
|
|
(i.getAttribute("class").indexOf("__caption") > 0 ||
|
|
/(SMALL|STRONG|EM)/i.test(i.tagName))
|
|
)
|
|
n.prevent = false;
|
|
}),
|
|
g("bindEvents", function () {
|
|
if (
|
|
(e.bind(s, "pswpTap click", T),
|
|
e.bind(t.scrollWrap, "pswpTap", n.onGlobalTap),
|
|
!t.likelyTouchDevice)
|
|
)
|
|
e.bind(t.scrollWrap, "mouseover", n.onMouseOver);
|
|
}),
|
|
g("unbindEvents", function () {
|
|
if (!p) L();
|
|
if (F) clearInterval(F);
|
|
if (
|
|
(e.unbind(document, "mouseout", H),
|
|
e.unbind(document, "mousemove", U),
|
|
e.unbind(s, "pswpTap click", T),
|
|
e.unbind(t.scrollWrap, "pswpTap", n.onGlobalTap),
|
|
e.unbind(t.scrollWrap, "mouseover", n.onMouseOver),
|
|
a)
|
|
) {
|
|
if (
|
|
(e.unbind(document, a.eventK, n.updateFullscreen),
|
|
a.isFullscreen())
|
|
)
|
|
(x.hideAnimationDuration = 0), a.exit();
|
|
a = null;
|
|
}
|
|
}),
|
|
g("destroy", function () {
|
|
if (x.captionEl) {
|
|
if (l) s.removeChild(l);
|
|
e.removeClass(u, "pswp__caption--empty");
|
|
}
|
|
if (h) h.children[0].onclick = null;
|
|
e.removeClass(s, "pswp__ui--over-close"),
|
|
e.addClass(s, "pswp__ui--hidden"),
|
|
n.setIdle(false);
|
|
}),
|
|
!x.showAnimationDuration)
|
|
)
|
|
e.removeClass(s, "pswp__ui--hidden");
|
|
if (
|
|
(g("initialZoomIn", function () {
|
|
if (x.showAnimationDuration) e.removeClass(s, "pswp__ui--hidden");
|
|
}),
|
|
g("initialZoomOut", function () {
|
|
e.addClass(s, "pswp__ui--hidden");
|
|
}),
|
|
g("parseVerticalMargin", W),
|
|
X(),
|
|
x.shareEl && c && h)
|
|
)
|
|
p = true;
|
|
k(), j(), $(), V();
|
|
}),
|
|
(n.setIdle = function (t) {
|
|
(v = t), E(s, "ui--idle", t);
|
|
}),
|
|
(n.update = function () {
|
|
if (o && t.currItem) {
|
|
if ((n.updateIndexIndicator(), x.captionEl))
|
|
x.addCaptionHTMLFn(t.currItem, u),
|
|
E(u, "caption--empty", !t.currItem.title);
|
|
i = true;
|
|
} else i = false;
|
|
if (!p) L();
|
|
k();
|
|
}),
|
|
(n.updateFullscreen = function (n) {
|
|
if (n)
|
|
setTimeout(function () {
|
|
t.setScrollOffset(0, e.getScrollY());
|
|
}, 50);
|
|
e[(a.isFullscreen() ? "add" : "remove") + "Class"](
|
|
t.template,
|
|
"pswp--fs"
|
|
);
|
|
}),
|
|
(n.updateIndexIndicator = function () {
|
|
if (x.counterEl)
|
|
f.innerHTML =
|
|
t.getCurrentIndex() +
|
|
1 +
|
|
x.indexIndicatorSep +
|
|
x.getNumItemsFn();
|
|
}),
|
|
(n.onGlobalTap = function (i) {
|
|
var a = (i = i || window.event).target || i.srcElement;
|
|
if (!A)
|
|
if (i.detail && "mouse" === i.detail.pointerType) {
|
|
if (P(a)) return t.close(), void 0;
|
|
if (e.hasClass(a, "pswp__img"))
|
|
if (
|
|
1 === t.getZoomLevel() &&
|
|
t.getZoomLevel() <= t.currItem.fitRatio
|
|
) {
|
|
if (x.clickToCloseNonZoomable) t.close();
|
|
} else t.toggleDesktopZoom(i.detail.releasePoint);
|
|
} else {
|
|
if (x.tapToToggleControls)
|
|
if (o) n.hideControls();
|
|
else n.showControls();
|
|
if (x.tapToClose && (e.hasClass(a, "pswp__img") || P(a)))
|
|
return t.close(), void 0;
|
|
}
|
|
}),
|
|
(n.onMouseOver = function (t) {
|
|
var e = (t = t || window.event).target || t.srcElement;
|
|
E(s, "ui--over-close", P(e));
|
|
}),
|
|
(n.hideControls = function () {
|
|
e.addClass(s, "pswp__ui--hidden"), (o = false);
|
|
}),
|
|
(n.showControls = function () {
|
|
if (((o = true), !i)) n.update();
|
|
e.removeClass(s, "pswp__ui--hidden");
|
|
}),
|
|
(n.supportsFullscreen = function () {
|
|
var d = document;
|
|
return !!(
|
|
d.exitFullscreen ||
|
|
d.mozCancelFullScreen ||
|
|
d.webkitExitFullscreen ||
|
|
d.msExitFullscreen
|
|
);
|
|
}),
|
|
(n.getFullscreenAPI = function () {
|
|
var e = document.documentElement,
|
|
n,
|
|
i = "fullscreenchange";
|
|
if (e.requestFullscreen)
|
|
n = {
|
|
enterK: "requestFullscreen",
|
|
exitK: "exitFullscreen",
|
|
elementK: "fullscreenElement",
|
|
eventK: i,
|
|
};
|
|
else if (e.mozRequestFullScreen)
|
|
n = {
|
|
enterK: "mozRequestFullScreen",
|
|
exitK: "mozCancelFullScreen",
|
|
elementK: "mozFullScreenElement",
|
|
eventK: "moz" + i,
|
|
};
|
|
else if (e.webkitRequestFullscreen)
|
|
n = {
|
|
enterK: "webkitRequestFullscreen",
|
|
exitK: "webkitExitFullscreen",
|
|
elementK: "webkitFullscreenElement",
|
|
eventK: "webkit" + i,
|
|
};
|
|
else if (e.msRequestFullscreen)
|
|
n = {
|
|
enterK: "msRequestFullscreen",
|
|
exitK: "msExitFullscreen",
|
|
elementK: "msFullscreenElement",
|
|
eventK: "MSFullscreenChange",
|
|
};
|
|
if (n)
|
|
(n.enter = function () {
|
|
if (
|
|
((m = x.closeOnScroll),
|
|
(x.closeOnScroll = false),
|
|
"webkitRequestFullscreen" === this.enterK)
|
|
)
|
|
t.template[this.enterK](Element.ALLOW_KEYBOARD_INPUT);
|
|
else return t.template[this.enterK]();
|
|
}),
|
|
(n.exit = function () {
|
|
return (x.closeOnScroll = m), document[this.exitK]();
|
|
}),
|
|
(n.isFullscreen = function () {
|
|
return document[this.elementK];
|
|
});
|
|
return n;
|
|
});
|
|
};
|
|
});
|
|
},
|
|
9816: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
if (!window.Utility) window.Utility = {};
|
|
(Utility.decodeJsonAttribute = function (t) {
|
|
return JSON.parse(decodeURIComponent(atob(t)));
|
|
}),
|
|
i(window.loadMapsContent);
|
|
},
|
|
9817: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
n(9818),
|
|
i(window).on("load", function () {
|
|
var t;
|
|
if (
|
|
!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(
|
|
navigator.userAgent || navigator.vendor || window.opera
|
|
)
|
|
) {
|
|
var items = i(".u-parallax");
|
|
if (items.length > 0) {
|
|
items.each(function () {
|
|
var t = i(this);
|
|
if (
|
|
(t.css("background-attachment", "fixed"),
|
|
t.hasClass("u-shading"))
|
|
)
|
|
t.attr(
|
|
"data-bottom-top",
|
|
"background-position: 50% 0, 50% 0vh;"
|
|
),
|
|
t.attr(
|
|
"data-top-bottom",
|
|
"background-position: 50% 0, 50% -20vh"
|
|
);
|
|
else
|
|
t.attr("data-bottom-top", "background-position: 50% 0vh;"),
|
|
t.attr("data-top-bottom", "background-position: 50% -20vh");
|
|
});
|
|
var e = { forceHeight: false };
|
|
skrollr.init(e);
|
|
}
|
|
}
|
|
});
|
|
},
|
|
9818: function (t, e) {
|
|
var e = void 0,
|
|
t = void 0;
|
|
(function () {
|
|
/*!
|
|
* skrollr core
|
|
*
|
|
* Alexander Prinzhorn - https://github.com/Prinzhorn/skrollr
|
|
*
|
|
* Free to use under terms of MIT license
|
|
*/
|
|
!(function (e, n, i) {
|
|
"use strict";
|
|
function o(t) {
|
|
if (
|
|
((f = n.documentElement),
|
|
(c = n.body),
|
|
K(),
|
|
(Mt = this),
|
|
(Nt = (t = t || {}).constants || {}),
|
|
t.easing)
|
|
)
|
|
for (var i in t.easing) nt[i] = t.easing[i];
|
|
if (
|
|
((Jt = t.edgeStrategy || "set"),
|
|
(Ot = {
|
|
beforerender: t.beforerender,
|
|
render: t.render,
|
|
keyframe: t.keyframe,
|
|
}),
|
|
(Pt = false !== t.forceHeight))
|
|
)
|
|
Rt = t.scale || 1;
|
|
if (
|
|
((zt = t.mobileDeceleration || I),
|
|
(jt = false !== t.smoothScrolling),
|
|
(Gt = t.smoothScrollingDuration || k),
|
|
(Zt = { targetTop: Mt.getScrollTop() }),
|
|
(Qt = (
|
|
t.mobileCheck ||
|
|
function () {
|
|
return /Android|iPhone|iPad|iPod|BlackBerry/i.test(
|
|
navigator.userAgent || navigator.vendor || e.opera
|
|
);
|
|
}
|
|
)()))
|
|
) {
|
|
if ((Bt = n.getElementById(t.skrollrBody || E))) mt();
|
|
rt(), At(f, [C, A], [x]);
|
|
} else At(f, [C, S], [x]);
|
|
Mt.refresh(),
|
|
vt(e, "resize orientationchange", function () {
|
|
var t = f.clientWidth,
|
|
e = f.clientHeight;
|
|
if (e !== Vt || t !== $t) (Vt = e), ($t = t), (Yt = true);
|
|
});
|
|
var o = J();
|
|
return (
|
|
!(function t() {
|
|
st(), (ie = o(t));
|
|
})(),
|
|
Mt
|
|
);
|
|
}
|
|
var a = {
|
|
get: function () {
|
|
return Mt;
|
|
},
|
|
init: function (t) {
|
|
return Mt || new o(t);
|
|
},
|
|
VERSION: "0.6.30",
|
|
},
|
|
s = Object.prototype.hasOwnProperty,
|
|
u = e.Math,
|
|
l = e.getComputedStyle,
|
|
f,
|
|
c,
|
|
h = "touchstart",
|
|
p = "touchmove",
|
|
m = "touchcancel",
|
|
v = "touchend",
|
|
g = "skrollable",
|
|
y = g + "-before",
|
|
w = g + "-between",
|
|
b = g + "-after",
|
|
C = "skrollr",
|
|
x = "no-" + C,
|
|
S = C + "-desktop",
|
|
A = C + "-mobile",
|
|
_ = "linear",
|
|
T = 1e3,
|
|
I = 0.004,
|
|
E = "skrollr-body",
|
|
k = 200,
|
|
M = "start",
|
|
L = "end",
|
|
B = "center",
|
|
O = "bottom",
|
|
P = "___skrollable_id",
|
|
F = /^(?:input|textarea|button|select)$/i,
|
|
N = /^\s+|\s+$/g,
|
|
z =
|
|
/^data(?:-(_\w+))?(?:-?(-?\d*\.?\d+p?))?(?:-?(start|end|top|center|bottom))?(?:-?(top|center|bottom))?$/,
|
|
U = /\s*(@?[\w\-\[\]]+)\s*:\s*(.+?)\s*(?:;|$)/gi,
|
|
H = /^(@?[a-z\-]+)\[(\w+)\]$/,
|
|
$ = /-([a-z0-9_])/g,
|
|
V = function (t, e) {
|
|
return e.toUpperCase();
|
|
},
|
|
Y = /[\-+]?[\d]*\.?[\d]+/g,
|
|
W = /\{\?\}/g,
|
|
j = /rgba?\(\s*-?\d+\s*,\s*-?\d+\s*,\s*-?\d+/g,
|
|
G = /[a-z\-]+-gradient/g,
|
|
Z = "",
|
|
X = "",
|
|
K = function () {
|
|
var t = /^(?:O|Moz|webkit|ms)|(?:-(?:o|moz|webkit|ms)-)/;
|
|
if (l) {
|
|
var style = l(c, null);
|
|
for (var e in style)
|
|
if ((Z = e.match(t) || (+e == e && style[e].match(t)))) break;
|
|
if (!Z) return (Z = X = ""), void 0;
|
|
if ("-" === (Z = Z[0]).slice(0, 1))
|
|
(X = Z),
|
|
(Z = {
|
|
"-webkit-": "webkit",
|
|
"-moz-": "Moz",
|
|
"-ms-": "ms",
|
|
"-o-": "O",
|
|
}[Z]);
|
|
else X = "-" + Z.toLowerCase() + "-";
|
|
}
|
|
},
|
|
J = function () {
|
|
var t =
|
|
e.requestAnimationFrame ||
|
|
e[Z.toLowerCase() + "RequestAnimationFrame"],
|
|
n = Dt();
|
|
if (Qt || !t)
|
|
t = function (t) {
|
|
var i = Dt() - n,
|
|
o = u.max(0, 1e3 / 60 - i);
|
|
return e.setTimeout(function () {
|
|
(n = Dt()), t();
|
|
}, o);
|
|
};
|
|
return t;
|
|
},
|
|
tt = function () {
|
|
var t =
|
|
e.cancelAnimationFrame ||
|
|
e[Z.toLowerCase() + "CancelAnimationFrame"];
|
|
if (Qt || !t)
|
|
t = function (t) {
|
|
return e.clearTimeout(t);
|
|
};
|
|
return t;
|
|
},
|
|
nt = {
|
|
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 -u.cos(t * u.PI) / 2 + 0.5;
|
|
},
|
|
sqrt: function (t) {
|
|
return u.sqrt(t);
|
|
},
|
|
outCubic: function (t) {
|
|
return u.pow(t - 1, 3) + 1;
|
|
},
|
|
bounce: function (t) {
|
|
var e;
|
|
if (t <= 0.5083) e = 3;
|
|
else if (t <= 0.8489) e = 9;
|
|
else if (t <= 0.96208) e = 27;
|
|
else if (t <= 0.99981) e = 91;
|
|
else return 1;
|
|
return 1 - u.abs((3 * u.cos(t * e * 1.028)) / e);
|
|
},
|
|
};
|
|
(o.prototype.refresh = function (t) {
|
|
var e,
|
|
o,
|
|
a = false;
|
|
if (t === i)
|
|
(a = true), (Lt = []), (Kt = 0), (t = n.getElementsByTagName("*"));
|
|
else if (t.length === i) t = [t];
|
|
for (e = 0, o = t.length; e < o; e++) {
|
|
var el = t[e],
|
|
s = el,
|
|
u = [],
|
|
l = jt,
|
|
f = Jt,
|
|
c = false;
|
|
if (a && P in el) delete el[P];
|
|
if (el.attributes) {
|
|
for (var h = 0, p = el.attributes.length; h < p; h++) {
|
|
var m = el.attributes[h];
|
|
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 v = m.name.match(z);
|
|
if (null !== v) {
|
|
var y = {
|
|
props: m.value,
|
|
element: el,
|
|
eventType: m.name.replace($, V),
|
|
};
|
|
u.push(y);
|
|
var w = v[1];
|
|
if (w) y.constant = w.substr(1);
|
|
var b = v[2];
|
|
if (/p$/.test(b))
|
|
(y.isPercentage = true),
|
|
(y.offset = (0 | b.slice(0, -1)) / 100);
|
|
else y.offset = 0 | b;
|
|
var C = v[3],
|
|
x = v[4] || C;
|
|
if (!C || C === M || C === L) {
|
|
if (((y.mode = "absolute"), C === L))
|
|
y.isEnd = true;
|
|
else if (!y.isPercentage) y.offset = y.offset * Rt;
|
|
} else (y.mode = "relative"), (y.anchors = [C, x]);
|
|
}
|
|
} else c = true;
|
|
else f = m.value;
|
|
else l = "off" !== m.value;
|
|
else if (null === (s = n.querySelector(m.value)))
|
|
throw 'Unable to find anchor target "' + m.value + '"';
|
|
}
|
|
if (u.length) {
|
|
var S, A, id;
|
|
if (!a && P in el)
|
|
(id = el[P]), (S = Lt[id].styleAttr), (A = Lt[id].classAttr);
|
|
else (id = el[P] = Kt++), (S = el.style.cssText), (A = St(el));
|
|
(Lt[id] = {
|
|
element: el,
|
|
styleAttr: S,
|
|
classAttr: A,
|
|
anchorTarget: s,
|
|
keyFrames: u,
|
|
smoothScrolling: l,
|
|
edgeStrategy: f,
|
|
emitEvents: c,
|
|
lastFrameIndex: -1,
|
|
}),
|
|
At(el, [g], []);
|
|
}
|
|
}
|
|
}
|
|
for (bt(), e = 0, o = t.length; e < o; e++) {
|
|
var sk = Lt[t[e][P]];
|
|
if (sk !== i) ut(sk), ft(sk);
|
|
}
|
|
return Mt;
|
|
}),
|
|
(o.prototype.relativeToAbsolute = function (t, e, n) {
|
|
var i = f.clientHeight,
|
|
o = t.getBoundingClientRect(),
|
|
a = o.top,
|
|
s = o.bottom - o.top;
|
|
if (e === O) a -= i;
|
|
else if (e === B) a -= i / 2;
|
|
if (n === O) a += s;
|
|
else if (n === B) a += s / 2;
|
|
return ((a += Mt.getScrollTop()) + 0.5) | 0;
|
|
}),
|
|
(o.prototype.animateTo = function (t, e) {
|
|
e = e || {};
|
|
var n = Dt(),
|
|
o = Mt.getScrollTop(),
|
|
a = e.duration === i ? T : e.duration;
|
|
if (
|
|
!(Wt = {
|
|
startTop: o,
|
|
topDiff: t - o,
|
|
targetTop: t,
|
|
duration: a,
|
|
startTime: n,
|
|
endTime: n + a,
|
|
easing: nt[e.easing || _],
|
|
done: e.done,
|
|
}).topDiff
|
|
) {
|
|
if (Wt.done) Wt.done.call(Mt, false);
|
|
Wt = i;
|
|
}
|
|
return Mt;
|
|
}),
|
|
(o.prototype.stopAnimateTo = function () {
|
|
if (Wt && Wt.done) Wt.done.call(Mt, true);
|
|
Wt = i;
|
|
}),
|
|
(o.prototype.isAnimatingTo = function () {
|
|
return !!Wt;
|
|
}),
|
|
(o.prototype.isMobile = function () {
|
|
return Qt;
|
|
}),
|
|
(o.prototype.setScrollTop = function (t, n) {
|
|
if (((Xt = true === n), Qt)) te = u.min(u.max(t, 0), Ft);
|
|
else e.scrollTo(0, t);
|
|
return Mt;
|
|
}),
|
|
(o.prototype.getScrollTop = function () {
|
|
if (Qt) return te;
|
|
else return e.pageYOffset || f.scrollTop || c.scrollTop || 0;
|
|
}),
|
|
(o.prototype.getMaxScrollTop = function () {
|
|
return Ft;
|
|
}),
|
|
(o.prototype.on = function (t, e) {
|
|
return (Ot[t] = e), Mt;
|
|
}),
|
|
(o.prototype.off = function (t) {
|
|
return delete Ot[t], Mt;
|
|
}),
|
|
(o.prototype.destroy = function () {
|
|
var t;
|
|
tt()(ie), yt(), At(f, [x], [C, S, A]);
|
|
for (var e = 0, n = Lt.length; e < n; e++) pt(Lt[e].element);
|
|
if (
|
|
((f.style.overflow = c.style.overflow = ""),
|
|
(f.style.height = c.style.height = ""),
|
|
Bt)
|
|
)
|
|
a.setStyle(Bt, "transform", "none");
|
|
(Mt = i),
|
|
(Bt = i),
|
|
(Ot = i),
|
|
(Pt = i),
|
|
(Ft = 0),
|
|
(Rt = 1),
|
|
(Nt = i),
|
|
(zt = i),
|
|
(Ut = "down"),
|
|
(qt = -1),
|
|
($t = 0),
|
|
(Vt = 0),
|
|
(Yt = false),
|
|
(Wt = i),
|
|
(jt = i),
|
|
(Gt = i),
|
|
(Zt = i),
|
|
(Xt = i),
|
|
(Kt = 0),
|
|
(Jt = i),
|
|
(Qt = false),
|
|
(te = 0),
|
|
(ee = i);
|
|
});
|
|
var rt = function () {
|
|
var t, o, a, s, l, g, y, w, b, C, x, S;
|
|
vt(f, [h, p, m, v].join(" "), function (e) {
|
|
var f = e.changedTouches[0];
|
|
for (s = e.target; 3 === s.nodeType;) s = s.parentNode;
|
|
if (
|
|
((l = f.clientY),
|
|
(g = f.clientX),
|
|
(C = e.timeStamp),
|
|
!F.test(s.tagName))
|
|
)
|
|
e.preventDefault();
|
|
switch (e.type) {
|
|
case h:
|
|
if (t) t.blur();
|
|
Mt.stopAnimateTo(), (t = s), (o = y = l), (a = g), (b = C);
|
|
break;
|
|
case p:
|
|
if (F.test(s.tagName) && n.activeElement !== s)
|
|
e.preventDefault();
|
|
(w = l - y),
|
|
(S = C - x),
|
|
Mt.setScrollTop(te - w, true),
|
|
(y = l),
|
|
(x = C);
|
|
break;
|
|
default:
|
|
case m:
|
|
case v:
|
|
var c = o - l,
|
|
A = a - g,
|
|
_;
|
|
if (A * A + c * c < 49) {
|
|
if (!F.test(t.tagName)) {
|
|
t.focus();
|
|
var T = n.createEvent("MouseEvents");
|
|
T.initMouseEvent(
|
|
"click",
|
|
true,
|
|
true,
|
|
e.view,
|
|
1,
|
|
f.screenX,
|
|
f.screenY,
|
|
f.clientX,
|
|
f.clientY,
|
|
e.ctrlKey,
|
|
e.altKey,
|
|
e.shiftKey,
|
|
e.metaKey,
|
|
0,
|
|
null
|
|
),
|
|
t.dispatchEvent(T);
|
|
}
|
|
return;
|
|
}
|
|
t = i;
|
|
var I = w / S;
|
|
I = u.max(u.min(I, 3), -3);
|
|
var E = u.abs(I / zt),
|
|
k = I * E + 0.5 * zt * E * E,
|
|
M = Mt.getScrollTop() - k,
|
|
L = 0;
|
|
if (M > Ft) (L = (Ft - M) / k), (M = Ft);
|
|
else if (M < 0) (L = -M / k), (M = 0);
|
|
(E *= 1 - L),
|
|
Mt.animateTo((M + 0.5) | 0, {
|
|
easing: "outCubic",
|
|
duration: E,
|
|
});
|
|
break;
|
|
}
|
|
}),
|
|
e.scrollTo(0, 0),
|
|
(f.style.overflow = c.style.overflow = "hidden");
|
|
},
|
|
ot = function () {
|
|
var t = f.clientHeight,
|
|
e = Ct(),
|
|
n,
|
|
i,
|
|
o,
|
|
a,
|
|
s,
|
|
l,
|
|
c,
|
|
h,
|
|
p,
|
|
m,
|
|
v;
|
|
for (h = 0, p = Lt.length; h < p; h++)
|
|
for (
|
|
i = (n = Lt[h]).element,
|
|
o = n.anchorTarget,
|
|
s = 0,
|
|
l = (a = n.keyFrames).length;
|
|
s < l;
|
|
s++
|
|
) {
|
|
if (
|
|
((m = (c = a[s]).offset),
|
|
(v = e[c.constant] || 0),
|
|
(c.frame = m),
|
|
c.isPercentage)
|
|
)
|
|
(m *= t), (c.frame = m);
|
|
if ("relative" === c.mode)
|
|
pt(i),
|
|
(c.frame =
|
|
Mt.relativeToAbsolute(o, c.anchors[0], c.anchors[1]) - m),
|
|
pt(i, true);
|
|
if (((c.frame += v), Pt))
|
|
if (!c.isEnd && c.frame > Ft) Ft = c.frame;
|
|
}
|
|
for (Ft = u.max(Ft, xt()), h = 0, p = Lt.length; h < p; h++) {
|
|
for (s = 0, l = (a = (n = Lt[h]).keyFrames).length; s < l; s++)
|
|
if (((v = e[(c = a[s]).constant] || 0), c.isEnd))
|
|
c.frame = Ft - c.offset + v;
|
|
n.keyFrames.sort(kt);
|
|
}
|
|
},
|
|
at = function (t, e) {
|
|
for (var n = 0, i = Lt.length; n < i; n++) {
|
|
var o = Lt[n],
|
|
u = o.element,
|
|
l = o.smoothScrolling ? t : e,
|
|
f = o.keyFrames,
|
|
c = f.length,
|
|
h = f[0],
|
|
p = f[f.length - 1],
|
|
m = l < h.frame,
|
|
v = l > p.frame,
|
|
C = m ? h : p,
|
|
x = o.emitEvents,
|
|
S = o.lastFrameIndex,
|
|
A,
|
|
_;
|
|
if (m || v) {
|
|
if ((m && -1 === o.edge) || (v && 1 === o.edge)) continue;
|
|
if (m) {
|
|
if ((At(u, [y], [b, w]), x && S > -1))
|
|
wt(u, h.eventType, Ut), (o.lastFrameIndex = -1);
|
|
} else if ((At(u, [b], [y, w]), x && S < c))
|
|
wt(u, p.eventType, Ut), (o.lastFrameIndex = c);
|
|
switch (((o.edge = m ? -1 : 1), o.edgeStrategy)) {
|
|
case "reset":
|
|
pt(u);
|
|
continue;
|
|
case "ease":
|
|
l = C.frame;
|
|
break;
|
|
default:
|
|
case "set":
|
|
var props = C.props;
|
|
for (A in props)
|
|
if (s.call(props, A))
|
|
if (((_ = ht(props[A].value)), 0 === A.indexOf("@")))
|
|
u.setAttribute(A.substr(1), _);
|
|
else a.setStyle(u, A, _);
|
|
continue;
|
|
}
|
|
} else if (0 !== o.edge) At(u, [g, w], [y, b]), (o.edge = 0);
|
|
for (var T = 0; T < c - 1; T++)
|
|
if (l >= f[T].frame && l <= f[T + 1].frame) {
|
|
var I = f[T],
|
|
E = f[T + 1];
|
|
for (A in I.props)
|
|
if (s.call(I.props, A)) {
|
|
var k = (l - I.frame) / (E.frame - I.frame);
|
|
if (
|
|
((k = I.props[A].easing(k)),
|
|
(_ = dt(I.props[A].value, E.props[A].value, k)),
|
|
(_ = ht(_)),
|
|
0 === A.indexOf("@"))
|
|
)
|
|
u.setAttribute(A.substr(1), _);
|
|
else a.setStyle(u, A, _);
|
|
}
|
|
if (x)
|
|
if (S !== T) {
|
|
if ("down" === Ut) wt(u, I.eventType, Ut);
|
|
else wt(u, E.eventType, Ut);
|
|
o.lastFrameIndex = T;
|
|
}
|
|
break;
|
|
}
|
|
}
|
|
},
|
|
st = function () {
|
|
if (Yt) (Yt = false), bt();
|
|
var t = Mt.getScrollTop(),
|
|
e,
|
|
n = Dt(),
|
|
o;
|
|
if (Wt) {
|
|
if (n >= Wt.endTime) (t = Wt.targetTop), (e = Wt.done), (Wt = i);
|
|
else
|
|
(o = Wt.easing((n - Wt.startTime) / Wt.duration)),
|
|
(t = (Wt.startTop + o * Wt.topDiff) | 0);
|
|
Mt.setScrollTop(t, true);
|
|
} else if (!Xt) {
|
|
var s;
|
|
if (Zt.targetTop - t)
|
|
Zt = {
|
|
startTop: qt,
|
|
topDiff: t - qt,
|
|
targetTop: t,
|
|
startTime: Ht,
|
|
endTime: Ht + Gt,
|
|
};
|
|
if (n <= Zt.endTime)
|
|
(o = nt.sqrt((n - Zt.startTime) / Gt)),
|
|
(t = (Zt.startTop + o * Zt.topDiff) | 0);
|
|
}
|
|
if (Xt || qt !== t) {
|
|
Xt = false;
|
|
var u = {
|
|
curTop: t,
|
|
lastTop: qt,
|
|
maxTop: Ft,
|
|
direction: (Ut = t > qt ? "down" : t < qt ? "up" : Ut),
|
|
},
|
|
l;
|
|
if (false !== (Ot.beforerender && Ot.beforerender.call(Mt, u))) {
|
|
if ((at(t, Mt.getScrollTop()), Qt && Bt))
|
|
a.setStyle(
|
|
Bt,
|
|
"transform",
|
|
"translate(0, " + -te + "px) " + ee
|
|
);
|
|
if (((qt = t), Ot.render)) Ot.render.call(Mt, u);
|
|
}
|
|
if (e) e.call(Mt, false);
|
|
}
|
|
Ht = n;
|
|
},
|
|
ut = function (t) {
|
|
for (var e = 0, n = t.keyFrames.length; e < n; e++) {
|
|
for (
|
|
var i = t.keyFrames[e], o, a, s, props = {}, u;
|
|
null !== (u = U.exec(i.props));
|
|
|
|
) {
|
|
if (((s = u[1]), (a = u[2]), null !== (o = s.match(H))))
|
|
(s = o[1]), (o = o[2]);
|
|
else o = _;
|
|
(a = a.indexOf("!") ? lt(a) : [a.slice(1)]),
|
|
(props[s] = { value: a, easing: nt[o] });
|
|
}
|
|
i.props = props;
|
|
}
|
|
},
|
|
lt = function (t) {
|
|
var e = [];
|
|
if (
|
|
((j.lastIndex = 0),
|
|
(t = t.replace(j, function (t) {
|
|
return t.replace(Y, function (t) {
|
|
return (t / 255) * 100 + "%";
|
|
});
|
|
})),
|
|
X)
|
|
)
|
|
(G.lastIndex = 0),
|
|
(t = t.replace(G, function (t) {
|
|
return X + t;
|
|
}));
|
|
return (
|
|
(t = t.replace(Y, function (t) {
|
|
return e.push(+t), "{?}";
|
|
})),
|
|
e.unshift(t),
|
|
e
|
|
);
|
|
},
|
|
ft = function (sk) {
|
|
var t = {},
|
|
e,
|
|
n;
|
|
for (e = 0, n = sk.keyFrames.length; e < n; e++)
|
|
ct(sk.keyFrames[e], t);
|
|
for (t = {}, e = sk.keyFrames.length - 1; e >= 0; e--)
|
|
ct(sk.keyFrames[e], t);
|
|
},
|
|
ct = function (t, e) {
|
|
var n;
|
|
for (n in e) if (!s.call(t.props, n)) t.props[n] = e[n];
|
|
for (n in t.props) e[n] = t.props[n];
|
|
},
|
|
dt = function (t, e, n) {
|
|
var i,
|
|
o = t.length;
|
|
if (o !== e.length)
|
|
throw (
|
|
"Can't interpolate between \"" + t[0] + '" and "' + e[0] + '"'
|
|
);
|
|
var a = [t[0]];
|
|
for (i = 1; i < o; i++) a[i] = t[i] + (e[i] - t[i]) * n;
|
|
return a;
|
|
},
|
|
ht = function (t) {
|
|
var e = 1;
|
|
return (
|
|
(W.lastIndex = 0),
|
|
t[0].replace(W, function () {
|
|
return t[e++];
|
|
})
|
|
);
|
|
},
|
|
pt = function (t, e) {
|
|
for (var n, i, o = 0, a = (t = [].concat(t)).length; o < a; o++)
|
|
if (((i = t[o]), (n = Lt[i[P]])))
|
|
if (e)
|
|
(i.style.cssText = n.dirtyStyleAttr), At(i, n.dirtyClassAttr);
|
|
else
|
|
(n.dirtyStyleAttr = i.style.cssText),
|
|
(n.dirtyClassAttr = St(i)),
|
|
(i.style.cssText = n.styleAttr),
|
|
At(i, n.classAttr);
|
|
},
|
|
mt = function () {
|
|
(ee = "translateZ(0)"), a.setStyle(Bt, "transform", ee);
|
|
var t = l(Bt),
|
|
e = t.getPropertyValue("transform"),
|
|
n = t.getPropertyValue(X + "transform"),
|
|
i;
|
|
if (!((e && "none" !== e) || (n && "none" !== n))) ee = "";
|
|
};
|
|
a.setStyle = function (el, t, e) {
|
|
var style = el.style;
|
|
if ("zIndex" === (t = t.replace($, V).replace("-", "")))
|
|
if (isNaN(e)) style[t] = e;
|
|
else style[t] = "" + (0 | e);
|
|
else if ("float" === t) style.styleFloat = style.cssFloat = e;
|
|
else
|
|
try {
|
|
if (Z) style[Z + t.slice(0, 1).toUpperCase() + t.slice(1)] = e;
|
|
style[t] = e;
|
|
} catch (t) { }
|
|
};
|
|
var vt = (a.addEvent = function (t, names, n) {
|
|
for (
|
|
var i = function (t) {
|
|
if (!(t = t || e.event).target) t.target = t.srcElement;
|
|
if (!t.preventDefault)
|
|
t.preventDefault = function () {
|
|
(t.returnValue = false), (t.defaultPrevented = true);
|
|
};
|
|
return n.call(this, t);
|
|
},
|
|
o,
|
|
a = 0,
|
|
s = (names = names.split(" ")).length;
|
|
a < s;
|
|
a++
|
|
) {
|
|
if (((o = names[a]), t.addEventListener))
|
|
t.addEventListener(o, n, false);
|
|
else t.attachEvent("on" + o, i);
|
|
ne.push({ element: t, name: o, listener: n });
|
|
}
|
|
}),
|
|
gt = (a.removeEvent = function (t, names, e) {
|
|
for (var n = 0, i = (names = names.split(" ")).length; n < i; n++)
|
|
if (t.removeEventListener)
|
|
t.removeEventListener(names[n], e, false);
|
|
else t.detachEvent("on" + names[n], e);
|
|
}),
|
|
yt = function () {
|
|
for (var t, e = 0, n = ne.length; e < n; e++)
|
|
(t = ne[e]), gt(t.element, t.name, t.listener);
|
|
ne = [];
|
|
},
|
|
wt = function (t, e, n) {
|
|
if (Ot.keyframe) Ot.keyframe.call(Mt, t, e, n);
|
|
},
|
|
bt = function () {
|
|
var t = Mt.getScrollTop();
|
|
if (((Ft = 0), Pt && !Qt)) c.style.height = "";
|
|
if ((ot(), Pt && !Qt)) c.style.height = Ft + f.clientHeight + "px";
|
|
if (Qt) Mt.setScrollTop(u.min(Mt.getScrollTop(), Ft));
|
|
else Mt.setScrollTop(t, true);
|
|
Xt = true;
|
|
},
|
|
Ct = function () {
|
|
var t = f.clientHeight,
|
|
copy = {},
|
|
e,
|
|
n;
|
|
for (e in Nt) {
|
|
if ("function" == typeof (n = Nt[e])) n = n.call(Mt);
|
|
else if (/p$/.test(n)) n = (n.slice(0, -1) / 100) * t;
|
|
copy[e] = n;
|
|
}
|
|
return copy;
|
|
},
|
|
xt = function () {
|
|
var t = 0,
|
|
e;
|
|
if (Bt) t = u.max(Bt.offsetHeight, Bt.scrollHeight);
|
|
return (
|
|
(e = u.max(
|
|
t,
|
|
c.scrollHeight,
|
|
c.offsetHeight,
|
|
f.scrollHeight,
|
|
f.offsetHeight,
|
|
f.clientHeight
|
|
)) - f.clientHeight
|
|
);
|
|
},
|
|
St = function (t) {
|
|
var n = "className";
|
|
if (e.SVGElement && t instanceof e.SVGElement)
|
|
(t = t[n]), (n = "baseVal");
|
|
return t[n];
|
|
},
|
|
At = function (t, add, remove) {
|
|
var n = "className";
|
|
if (e.SVGElement && t instanceof e.SVGElement)
|
|
(t = t[n]), (n = "baseVal");
|
|
if (remove === i) return (t[n] = add), void 0;
|
|
for (var o = t[n], a = 0, s = remove.length; a < s; a++)
|
|
o = Tt(o).replace(Tt(remove[a]), " ");
|
|
o = _t(o);
|
|
for (var u = 0, l = add.length; u < l; u++)
|
|
if (-1 === Tt(o).indexOf(Tt(add[u]))) o += " " + add[u];
|
|
t[n] = _t(o);
|
|
},
|
|
_t = function (t) {
|
|
return t.replace(N, "");
|
|
},
|
|
Tt = function (t) {
|
|
return " " + t + " ";
|
|
},
|
|
Dt =
|
|
Date.now ||
|
|
function () {
|
|
return +new Date();
|
|
},
|
|
kt = function (t, e) {
|
|
return t.frame - e.frame;
|
|
},
|
|
Mt,
|
|
Lt,
|
|
Bt,
|
|
Ot,
|
|
Pt,
|
|
Ft = 0,
|
|
Rt = 1,
|
|
Nt,
|
|
zt,
|
|
Ut = "down",
|
|
qt = -1,
|
|
Ht = Dt(),
|
|
$t = 0,
|
|
Vt = 0,
|
|
Yt = false,
|
|
Wt,
|
|
jt,
|
|
Gt,
|
|
Zt,
|
|
Xt,
|
|
Kt = 0,
|
|
Jt,
|
|
Qt = false,
|
|
te = 0,
|
|
ee,
|
|
ne = [],
|
|
ie;
|
|
if ("function" == typeof define && define.amd)
|
|
define([], function () {
|
|
return a;
|
|
});
|
|
else if (void 0 !== t && t.exports) t.exports = a;
|
|
else e.skrollr = a;
|
|
})(window, document);
|
|
}).call(window);
|
|
},
|
|
9819: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
this.initialize(t);
|
|
}
|
|
function o(t) {
|
|
if (!window.getComputedStyle) return null;
|
|
var transform = getComputedStyle(t).transform,
|
|
e = /matrix\(([^)]+)\)/.exec(transform);
|
|
if (!e || e.length < 2) return null;
|
|
if ((e = e[1].split(",")).length < 6) return null;
|
|
else
|
|
return {
|
|
a: parseFloat(e[0], 10),
|
|
b: parseFloat(e[1], 10),
|
|
c: parseFloat(e[2], 10),
|
|
d: parseFloat(e[3], 10),
|
|
tx: parseFloat(e[4], 10),
|
|
ty: parseFloat(e[5], 10),
|
|
};
|
|
}
|
|
function a(t, e, n, i) {
|
|
var a = o(e),
|
|
s = 0,
|
|
u = 0,
|
|
l,
|
|
f;
|
|
if (a && !isNaN(a.tx)) s = a.tx;
|
|
if (a && !isNaN(a.ty)) u = a.ty;
|
|
if ("horizontal" === n) (l = t.innerWidth()), (f = s);
|
|
else (l = t.innerHeight()), (f = u);
|
|
return Math.ceil(l * i + f);
|
|
}
|
|
function s(t) {
|
|
if (!t && !t.element) return false;
|
|
var e = t.element.getAttribute("data-animation-name");
|
|
if (e && "slidein" === e.toLowerCase()) return true;
|
|
else return false;
|
|
}
|
|
function u(t) {
|
|
if (!s(t)) return t;
|
|
var e = t.offset;
|
|
if ("string" == typeof e)
|
|
if (((e = parseFloat(e)), t.offset.indexOf("%") > -1)) e /= 100;
|
|
return (
|
|
((t = $.extend({}, t)).offset = function () {
|
|
return a(this.context, this.element, this.axis, e);
|
|
}),
|
|
t
|
|
);
|
|
}
|
|
n(9820),
|
|
(i.prototype.initialize = function t(e) {
|
|
if (!this.waypoint)
|
|
if (e && e.element && "function" == typeof e.handler)
|
|
(e = u(e)), (this.waypoint = new Waypoint(e));
|
|
}),
|
|
(i.prototype.destroy = function t() {
|
|
if (this.waypoint) this.waypoint.destroy(), (this.waypoint = null);
|
|
}),
|
|
(window.WaypointAdapter = i);
|
|
},
|
|
9820: function (t, e) {
|
|
var e = void 0,
|
|
t = void 0;
|
|
(function () {
|
|
/*!
|
|
Waypoints - 4.0.1
|
|
Copyright © 2011-2016 Caleb Troughton
|
|
Licensed under the MIT license.
|
|
https://github.com/imakewebthings/waypoints/blob/master/licenses.txt
|
|
*/
|
|
!(function () {
|
|
"use strict";
|
|
function t(i) {
|
|
if (!i) throw new Error("No options passed to Waypoint constructor");
|
|
if (!i.element)
|
|
throw new Error("No element option passed to Waypoint constructor");
|
|
if (!i.handler)
|
|
throw new Error("No handler option passed to Waypoint constructor");
|
|
if (
|
|
((this.key = "waypoint-" + e),
|
|
(this.options = t.Adapter.extend({}, t.defaults, i)),
|
|
(this.element = this.options.element),
|
|
(this.adapter = new t.Adapter(this.element)),
|
|
(this.callback = i.handler),
|
|
(this.axis = this.options.horizontal ? "horizontal" : "vertical"),
|
|
(this.enabled = this.options.enabled),
|
|
(this.triggerPoint = null),
|
|
(this.group = t.Group.findOrCreate({
|
|
name: this.options.group,
|
|
axis: this.axis,
|
|
})),
|
|
(this.context = t.Context.findOrCreateByElement(
|
|
this.options.context
|
|
)),
|
|
t.offsetAliases[this.options.offset])
|
|
)
|
|
this.options.offset = t.offsetAliases[this.options.offset];
|
|
this.group.add(this),
|
|
this.context.add(this),
|
|
(n[this.key] = this),
|
|
(e += 1);
|
|
}
|
|
var e = 0,
|
|
n = {};
|
|
(t.prototype.queueTrigger = function (t) {
|
|
this.group.queueTrigger(this, t);
|
|
}),
|
|
(t.prototype.trigger = function (t) {
|
|
if (this.enabled) if (this.callback) this.callback.apply(this, t);
|
|
}),
|
|
(t.prototype.destroy = function () {
|
|
this.context.remove(this),
|
|
this.group.remove(this),
|
|
delete n[this.key];
|
|
}),
|
|
(t.prototype.disable = function () {
|
|
return (this.enabled = false), this;
|
|
}),
|
|
(t.prototype.enable = function () {
|
|
return this.context.refresh(), (this.enabled = true), this;
|
|
}),
|
|
(t.prototype.next = function () {
|
|
return this.group.next(this);
|
|
}),
|
|
(t.prototype.previous = function () {
|
|
return this.group.previous(this);
|
|
}),
|
|
(t.invokeAll = function (t) {
|
|
var e = [];
|
|
for (var i in n) e.push(n[i]);
|
|
for (var o = 0, a = e.length; o < a; o++) e[o][t]();
|
|
}),
|
|
(t.destroyAll = function () {
|
|
t.invokeAll("destroy");
|
|
}),
|
|
(t.disableAll = function () {
|
|
t.invokeAll("disable");
|
|
}),
|
|
(t.enableAll = function () {
|
|
for (var e in (t.Context.refreshAll(), n)) n[e].enabled = true;
|
|
return this;
|
|
}),
|
|
(t.refreshAll = function () {
|
|
t.Context.refreshAll();
|
|
}),
|
|
(t.viewportHeight = function () {
|
|
return window.innerHeight || document.documentElement.clientHeight;
|
|
}),
|
|
(t.viewportWidth = function () {
|
|
return document.documentElement.clientWidth;
|
|
}),
|
|
(t.adapters = []),
|
|
(t.defaults = {
|
|
context: window,
|
|
continuous: true,
|
|
enabled: true,
|
|
group: "default",
|
|
horizontal: false,
|
|
offset: 0,
|
|
}),
|
|
(t.offsetAliases = {
|
|
"bottom-in-view": function () {
|
|
return this.context.innerHeight() - this.adapter.outerHeight();
|
|
},
|
|
"right-in-view": function () {
|
|
return this.context.innerWidth() - this.adapter.outerWidth();
|
|
},
|
|
}),
|
|
(window.Waypoint = t);
|
|
})(),
|
|
(function () {
|
|
"use strict";
|
|
function t(t) {
|
|
window.setTimeout(t, 1e3 / 60);
|
|
}
|
|
function e(t) {
|
|
if (
|
|
((this.element = t),
|
|
(this.Adapter = o.Adapter),
|
|
(this.adapter = new this.Adapter(t)),
|
|
(this.key = "waypoint-context-" + n),
|
|
(this.didScroll = false),
|
|
(this.didResize = false),
|
|
(this.oldScroll = {
|
|
x: this.adapter.scrollLeft(),
|
|
y: this.adapter.scrollTop(),
|
|
}),
|
|
(this.waypoints = { vertical: {}, horizontal: {} }),
|
|
(t.waypointContextKey = this.key),
|
|
(i[t.waypointContextKey] = this),
|
|
(n += 1),
|
|
!o.windowContext)
|
|
)
|
|
(o.windowContext = true), (o.windowContext = new e(window));
|
|
this.createThrottledScrollHandler(),
|
|
this.createThrottledResizeHandler();
|
|
}
|
|
var n = 0,
|
|
i = {},
|
|
o = window.Waypoint,
|
|
a = window.onload;
|
|
(e.prototype.add = function (t) {
|
|
var e = t.options.horizontal ? "horizontal" : "vertical";
|
|
(this.waypoints[e][t.key] = t), this.refresh();
|
|
}),
|
|
(e.prototype.checkEmpty = function () {
|
|
var t = this.Adapter.isEmptyObject(this.waypoints.horizontal),
|
|
e = this.Adapter.isEmptyObject(this.waypoints.vertical),
|
|
n = this.element == this.element.window;
|
|
if (t && e && !n)
|
|
this.adapter.off(".waypoints"), delete i[this.key];
|
|
}),
|
|
(e.prototype.createThrottledResizeHandler = function () {
|
|
function t() {
|
|
e.handleResize(), (e.didResize = false);
|
|
}
|
|
var e = this;
|
|
this.adapter.on("resize.waypoints", function () {
|
|
if (!e.didResize)
|
|
(e.didResize = true), o.requestAnimationFrame(t);
|
|
});
|
|
}),
|
|
(e.prototype.createThrottledScrollHandler = function () {
|
|
function t() {
|
|
e.handleScroll(), (e.didScroll = false);
|
|
}
|
|
var e = this;
|
|
this.adapter.on("scroll.waypoints", function () {
|
|
if (!e.didScroll || o.isTouch)
|
|
(e.didScroll = true), o.requestAnimationFrame(t);
|
|
});
|
|
}),
|
|
(e.prototype.handleResize = function () {
|
|
o.Context.refreshAll();
|
|
}),
|
|
(e.prototype.handleScroll = function () {
|
|
var t = {},
|
|
e = {
|
|
horizontal: {
|
|
newScroll: this.adapter.scrollLeft(),
|
|
oldScroll: this.oldScroll.x,
|
|
forward: "right",
|
|
backward: "left",
|
|
},
|
|
vertical: {
|
|
newScroll: this.adapter.scrollTop(),
|
|
oldScroll: this.oldScroll.y,
|
|
forward: "down",
|
|
backward: "up",
|
|
},
|
|
};
|
|
for (var n in e) {
|
|
var i = e[n],
|
|
o,
|
|
a = i.newScroll > i.oldScroll ? i.forward : i.backward;
|
|
for (var s in this.waypoints[n]) {
|
|
var u = this.waypoints[n][s];
|
|
if (null !== u.triggerPoint) {
|
|
var l = i.oldScroll < u.triggerPoint,
|
|
f = i.newScroll >= u.triggerPoint,
|
|
c,
|
|
h;
|
|
if ((l && f) || (!l && !f))
|
|
u.queueTrigger(a), (t[u.group.id] = u.group);
|
|
}
|
|
}
|
|
}
|
|
for (var p in t) t[p].flushTriggers();
|
|
this.oldScroll = {
|
|
x: e.horizontal.newScroll,
|
|
y: e.vertical.newScroll,
|
|
};
|
|
}),
|
|
(e.prototype.innerHeight = function () {
|
|
if (this.element == this.element.window)
|
|
return o.viewportHeight();
|
|
else return this.adapter.innerHeight();
|
|
}),
|
|
(e.prototype.remove = function (t) {
|
|
delete this.waypoints[t.axis][t.key], this.checkEmpty();
|
|
}),
|
|
(e.prototype.innerWidth = function () {
|
|
if (this.element == this.element.window) return o.viewportWidth();
|
|
else return this.adapter.innerWidth();
|
|
}),
|
|
(e.prototype.destroy = function () {
|
|
var t = [];
|
|
for (var e in this.waypoints)
|
|
for (var n in this.waypoints[e]) t.push(this.waypoints[e][n]);
|
|
for (var i = 0, o = t.length; i < o; i++) t[i].destroy();
|
|
}),
|
|
(e.prototype.refresh = function () {
|
|
var t = this.element == this.element.window,
|
|
e = t ? void 0 : this.adapter.offset(),
|
|
n = {},
|
|
i;
|
|
for (var a in (this.handleScroll(),
|
|
(i = {
|
|
horizontal: {
|
|
contextOffset: t ? 0 : e.left,
|
|
contextScroll: t ? 0 : this.oldScroll.x,
|
|
contextDimension: this.innerWidth(),
|
|
oldScroll: this.oldScroll.x,
|
|
forward: "right",
|
|
backward: "left",
|
|
offsetProp: "left",
|
|
},
|
|
vertical: {
|
|
contextOffset: t ? 0 : e.top,
|
|
contextScroll: t ? 0 : this.oldScroll.y,
|
|
contextDimension: this.innerHeight(),
|
|
oldScroll: this.oldScroll.y,
|
|
forward: "down",
|
|
backward: "up",
|
|
offsetProp: "top",
|
|
},
|
|
}))) {
|
|
var s = i[a];
|
|
for (var u in this.waypoints[a]) {
|
|
var l = this.waypoints[a][u],
|
|
f = l.options.offset,
|
|
c = l.triggerPoint,
|
|
h = 0,
|
|
p = null == c,
|
|
m,
|
|
v,
|
|
g,
|
|
y,
|
|
w;
|
|
if (l.element !== l.element.window)
|
|
h = l.adapter.offset()[s.offsetProp];
|
|
if ("function" == typeof f) f = f.apply(l);
|
|
else if ("string" == typeof f)
|
|
if (
|
|
((f = parseFloat(f)), l.options.offset.indexOf("%") > -1)
|
|
)
|
|
f = Math.ceil((s.contextDimension * f) / 100);
|
|
if (
|
|
((m = s.contextScroll - s.contextOffset),
|
|
(l.triggerPoint = Math.floor(h + m - f)),
|
|
(v = c < s.oldScroll),
|
|
(g = l.triggerPoint >= s.oldScroll),
|
|
(w = !v && !g),
|
|
!p && (y = v && g))
|
|
)
|
|
l.queueTrigger(s.backward), (n[l.group.id] = l.group);
|
|
else if (!p && w)
|
|
l.queueTrigger(s.forward), (n[l.group.id] = l.group);
|
|
else if (p && s.oldScroll >= l.triggerPoint)
|
|
l.queueTrigger(s.forward), (n[l.group.id] = l.group);
|
|
}
|
|
}
|
|
return (
|
|
o.requestAnimationFrame(function () {
|
|
for (var t in n) n[t].flushTriggers();
|
|
}),
|
|
this
|
|
);
|
|
}),
|
|
(e.findOrCreateByElement = function (t) {
|
|
return e.findByElement(t) || new e(t);
|
|
}),
|
|
(e.refreshAll = function () {
|
|
for (var t in i) i[t].refresh();
|
|
}),
|
|
(e.findByElement = function (t) {
|
|
return i[t.waypointContextKey];
|
|
}),
|
|
(window.onload = function () {
|
|
if (a) a();
|
|
e.refreshAll();
|
|
}),
|
|
(o.requestAnimationFrame = function (e) {
|
|
var n;
|
|
(
|
|
window.requestAnimationFrame ||
|
|
window.mozRequestAnimationFrame ||
|
|
window.webkitRequestAnimationFrame ||
|
|
t
|
|
).call(window, e);
|
|
}),
|
|
(o.Context = e);
|
|
})(),
|
|
(function () {
|
|
"use strict";
|
|
function t(t, e) {
|
|
return t.triggerPoint - e.triggerPoint;
|
|
}
|
|
function e(t, e) {
|
|
return e.triggerPoint - t.triggerPoint;
|
|
}
|
|
function Group(t) {
|
|
(this.name = t.name),
|
|
(this.axis = t.axis),
|
|
(this.id = this.name + "-" + this.axis),
|
|
(this.waypoints = []),
|
|
this.clearTriggerQueues(),
|
|
(n[this.axis][this.name] = this);
|
|
}
|
|
var n = { vertical: {}, horizontal: {} },
|
|
i = window.Waypoint;
|
|
(Group.prototype.add = function (t) {
|
|
this.waypoints.push(t);
|
|
}),
|
|
(Group.prototype.clearTriggerQueues = function () {
|
|
this.triggerQueues = { up: [], down: [], left: [], right: [] };
|
|
}),
|
|
(Group.prototype.flushTriggers = function () {
|
|
for (var n in this.triggerQueues) {
|
|
var i = this.triggerQueues[n],
|
|
o = "up" === n || "left" === n;
|
|
i.sort(o ? e : t);
|
|
for (var a = 0, s = i.length; a < s; a += 1) {
|
|
var u = i[a];
|
|
if (u.options.continuous || a === i.length - 1)
|
|
u.trigger([n]);
|
|
}
|
|
}
|
|
this.clearTriggerQueues();
|
|
}),
|
|
(Group.prototype.next = function (e) {
|
|
this.waypoints.sort(t);
|
|
var index = i.Adapter.inArray(e, this.waypoints),
|
|
n;
|
|
return index === this.waypoints.length - 1
|
|
? null
|
|
: this.waypoints[index + 1];
|
|
}),
|
|
(Group.prototype.previous = function (e) {
|
|
this.waypoints.sort(t);
|
|
var index = i.Adapter.inArray(e, this.waypoints);
|
|
return index ? this.waypoints[index - 1] : null;
|
|
}),
|
|
(Group.prototype.queueTrigger = function (t, e) {
|
|
this.triggerQueues[e].push(t);
|
|
}),
|
|
(Group.prototype.remove = function (t) {
|
|
var index = i.Adapter.inArray(t, this.waypoints);
|
|
if (index > -1) this.waypoints.splice(index, 1);
|
|
}),
|
|
(Group.prototype.first = function () {
|
|
return this.waypoints[0];
|
|
}),
|
|
(Group.prototype.last = function () {
|
|
return this.waypoints[this.waypoints.length - 1];
|
|
}),
|
|
(Group.findOrCreate = function (t) {
|
|
return n[t.axis][t.name] || new Group(t);
|
|
}),
|
|
(i.Group = Group);
|
|
})(),
|
|
(function () {
|
|
"use strict";
|
|
function t(t) {
|
|
return t === t.window;
|
|
}
|
|
function e(e) {
|
|
if (t(e)) return e;
|
|
else return e.defaultView;
|
|
}
|
|
function n(t) {
|
|
(this.element = t), (this.handlers = {});
|
|
}
|
|
var i = window.Waypoint;
|
|
(n.prototype.innerHeight = function () {
|
|
var e;
|
|
return t(this.element)
|
|
? this.element.innerHeight
|
|
: this.element.clientHeight;
|
|
}),
|
|
(n.prototype.innerWidth = function () {
|
|
var e;
|
|
return t(this.element)
|
|
? this.element.innerWidth
|
|
: this.element.clientWidth;
|
|
}),
|
|
(n.prototype.off = function (t, e) {
|
|
function n(t, e, n) {
|
|
for (var i = 0, o = e.length - 1; i < o; i++) {
|
|
var a = e[i];
|
|
if (!n || n === a) t.removeEventListener(a);
|
|
}
|
|
}
|
|
var i = t.split("."),
|
|
o = i[0],
|
|
a = i[1],
|
|
s = this.element;
|
|
if (a && this.handlers[a] && o)
|
|
n(s, this.handlers[a][o], e), (this.handlers[a][o] = []);
|
|
else if (o)
|
|
for (var u in this.handlers)
|
|
n(s, this.handlers[u][o] || [], e),
|
|
(this.handlers[u][o] = []);
|
|
else if (a && this.handlers[a]) {
|
|
for (var type in this.handlers[a])
|
|
n(s, this.handlers[a][type], e);
|
|
this.handlers[a] = {};
|
|
}
|
|
}),
|
|
(n.prototype.offset = function () {
|
|
if (!this.element.ownerDocument) return null;
|
|
var t = this.element.ownerDocument.documentElement,
|
|
n = e(this.element.ownerDocument),
|
|
rect = { top: 0, left: 0 };
|
|
if (this.element.getBoundingClientRect)
|
|
rect = this.element.getBoundingClientRect();
|
|
return {
|
|
top: rect.top + n.pageYOffset - t.clientTop,
|
|
left: rect.left + n.pageXOffset - t.clientLeft,
|
|
};
|
|
}),
|
|
(n.prototype.on = function (t, e) {
|
|
var n = t.split("."),
|
|
i = n[0],
|
|
o = n[1] || "__default",
|
|
a = (this.handlers[o] = this.handlers[o] || {}),
|
|
s;
|
|
(a[i] = a[i] || []).push(e), this.element.addEventListener(i, e);
|
|
}),
|
|
(n.prototype.outerHeight = function (e) {
|
|
var n = this.innerHeight(),
|
|
i;
|
|
if (e && !t(this.element))
|
|
(i = window.getComputedStyle(this.element)),
|
|
(n += parseInt(i.marginTop, 10)),
|
|
(n += parseInt(i.marginBottom, 10));
|
|
return n;
|
|
}),
|
|
(n.prototype.outerWidth = function (e) {
|
|
var n = this.innerWidth(),
|
|
i;
|
|
if (e && !t(this.element))
|
|
(i = window.getComputedStyle(this.element)),
|
|
(n += parseInt(i.marginLeft, 10)),
|
|
(n += parseInt(i.marginRight, 10));
|
|
return n;
|
|
}),
|
|
(n.prototype.scrollLeft = function () {
|
|
var t = e(this.element);
|
|
return t ? t.pageXOffset : this.element.scrollLeft;
|
|
}),
|
|
(n.prototype.scrollTop = function () {
|
|
var t = e(this.element);
|
|
return t ? t.pageYOffset : this.element.scrollTop;
|
|
}),
|
|
(n.extend = function () {
|
|
function merge(t, e) {
|
|
if ("object" == typeof t && "object" == typeof e)
|
|
for (var n in e) if (e.hasOwnProperty(n)) t[n] = e[n];
|
|
return t;
|
|
}
|
|
for (
|
|
var t = Array.prototype.slice.call(arguments),
|
|
e = 1,
|
|
n = t.length;
|
|
e < n;
|
|
e++
|
|
)
|
|
merge(t[0], t[e]);
|
|
return t[0];
|
|
}),
|
|
(n.inArray = function (t, e, n) {
|
|
return null == e ? -1 : e.indexOf(t, n);
|
|
}),
|
|
(n.isEmptyObject = function (t) {
|
|
for (var e in t) return false;
|
|
return true;
|
|
}),
|
|
i.adapters.push({ name: "noframework", Adapter: n }),
|
|
(i.Adapter = n);
|
|
})();
|
|
}).call(window);
|
|
},
|
|
9821: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(document).ready(function () {
|
|
function t(t) {
|
|
return e() ? 0 : n(t);
|
|
}
|
|
function e() {
|
|
return a.hasClass("u-overlap");
|
|
}
|
|
function n(t) {
|
|
var rect;
|
|
return t[0].getBoundingClientRect().height;
|
|
}
|
|
var o = i("header.u-sticky");
|
|
if (
|
|
o.length &&
|
|
!o.closest(".u-overlap").length &&
|
|
!CSS.supports("position", "sticky") &&
|
|
!CSS.supports("position", "-webkit-sticky")
|
|
) {
|
|
o.css("width", "100%");
|
|
var update = function () {
|
|
o.each(function () {
|
|
var t = i(this),
|
|
e = t.height(),
|
|
n = t.data("additionalMargin") || 0;
|
|
if (e !== n) {
|
|
t.data("additionalMargin", e);
|
|
var o = t;
|
|
do {
|
|
o = o.next();
|
|
} while (o.length > 0 && "none" === o.css("display"));
|
|
o.css(
|
|
"margin-top",
|
|
parseFloat(o.css("margin-top")) - n + e + "px"
|
|
);
|
|
}
|
|
});
|
|
};
|
|
update(), i(window).load(update), i(window).resize(update);
|
|
}
|
|
var a = i(".u-body");
|
|
if (a.hasClass("u-overlap-transparent"))
|
|
a.data("overlap-transparent", true);
|
|
if (a.hasClass("u-overlap-contrast")) a.data("overlap-contrast", true);
|
|
i(window).scroll(function e() {
|
|
i("header.u-sticky").each(function () {
|
|
var e = i(this),
|
|
n = e.nextAll(":visible:first");
|
|
if (n.length) {
|
|
var o = n.offset().top,
|
|
s = e.offset().top,
|
|
u,
|
|
l = s + t(e) > o,
|
|
f;
|
|
if ((a.toggleClass("u-sticky-fixed", l), s > o))
|
|
a.addClass("u-sticky-scroll"),
|
|
a.removeClass("u-overlap-transparent u-overlap-contrast");
|
|
else
|
|
a.toggleClass(
|
|
"u-overlap-transparent",
|
|
!!a.data("overlap-transparent")
|
|
),
|
|
a.toggleClass(
|
|
"u-overlap-contrast",
|
|
!!a.data("overlap-contrast")
|
|
),
|
|
a.removeClass("u-sticky-scroll");
|
|
}
|
|
});
|
|
});
|
|
});
|
|
},
|
|
9822: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
function e() {
|
|
f = [];
|
|
var e = o("html").scrollTop();
|
|
t.each(function () {
|
|
var rect = this.getBoundingClientRect();
|
|
f.push({ height: rect.height, top: rect.top + e });
|
|
});
|
|
}
|
|
function n(index) {
|
|
for (var e = 0, n = 0; n < index; n++) {
|
|
var i;
|
|
if (t.eq(n).hasClass(c)) {
|
|
var rect;
|
|
e += (f[n] || {}).height || 0;
|
|
}
|
|
}
|
|
return e;
|
|
}
|
|
function i() {
|
|
l.refresh();
|
|
}
|
|
function a() {
|
|
clearTimeout(p),
|
|
(p = setTimeout(function () {
|
|
for (var n = 0; n < t.length; n++) {
|
|
var i;
|
|
u(t.eq(n));
|
|
}
|
|
e(), l.refresh();
|
|
}, 25));
|
|
}
|
|
function s(t, e, n) {
|
|
if (!(t = o(t)).hasClass(c)) {
|
|
var i = o("<div></div>");
|
|
i.addClass(h),
|
|
i.css("height", e + "px"),
|
|
t.after(i),
|
|
t.addClass(c),
|
|
t.css("top", n + "px");
|
|
}
|
|
}
|
|
function u(t) {
|
|
(t = o(t)).nextAll("." + h).remove(),
|
|
t.removeClass(c),
|
|
t.css("top", "");
|
|
}
|
|
var l = {},
|
|
f = [],
|
|
c = "u-sticky-fixed",
|
|
h = "u-sticky-placeholder",
|
|
p = null;
|
|
return (
|
|
(l.init = function init() {
|
|
o(window).on("scroll", i), o(window).on("resize", a), e();
|
|
}),
|
|
(l.destroy = function t() {
|
|
o(window).off("scroll", i), o(window).off("resize", a);
|
|
}),
|
|
(l.refresh = function e() {
|
|
var i = o("html").scrollTop();
|
|
t.each(function (t, el) {
|
|
var e = n(t);
|
|
if (i + e > f[t].top) s(el, f[t].height, e);
|
|
else u(el);
|
|
});
|
|
}),
|
|
l
|
|
);
|
|
}
|
|
var o = n(10);
|
|
o(window).on("load", function () {
|
|
var t,
|
|
sticky = i(o(".u-section-row.u-sticky"));
|
|
sticky.init(), sticky.refresh();
|
|
}),
|
|
(window._npStickyStack = i);
|
|
},
|
|
9823: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(function () {
|
|
i(".u-nav-container .u-nav-link").each(function () {
|
|
window._npInitMenuLink(i(this));
|
|
}),
|
|
i(".u-nav-container-collapse .u-nav-link").each(function () {
|
|
window._npInitMenuLink(i(this), true);
|
|
});
|
|
}),
|
|
(window._npInitMenuLink = function t(e, n) {
|
|
var o = i("body"),
|
|
a = /#.*?$/,
|
|
s = o.attr("data-home-page-name"),
|
|
homePage = o.attr("data-home-page"),
|
|
pageTitle = i("title").text().trim(),
|
|
nav = e.closest(".u-menu"),
|
|
u = nav.attr("data-submenu-level") || "on-click",
|
|
l = nav.is(".u-menu-mega"),
|
|
f = e.attr("href") || "",
|
|
c = (e[0].href || "").replace(a, ""),
|
|
h = f.replace(a, ""),
|
|
p = s || pageTitle,
|
|
m = e.text().trim(),
|
|
hash = f.replace(/^[^#]+/, "");
|
|
if (!hash || "#" === hash || !i(hash).length) {
|
|
var v = c.split(".").slice(0, -1).join("."),
|
|
pageName = h.replace(".html", ""),
|
|
g = new RegExp(pageName + "_[\\s\\S]+?.html", "gm");
|
|
if (
|
|
(h && window.location.href.toString() === c) ||
|
|
(h && window.location.href.toString() === v) ||
|
|
(h && window.location.href.toString().search(g) > -1) ||
|
|
(m && p === m) ||
|
|
(homePage && h === homePage)
|
|
) {
|
|
var y = e;
|
|
if (!l || n) y = e.parents(".u-nav-item").children(".u-nav-link");
|
|
if ((y.addClass("active"), "with-reload" === u && n))
|
|
y.siblings(".u-nav-popup")
|
|
.addClass("open")
|
|
.css("max-height", "none");
|
|
}
|
|
}
|
|
});
|
|
},
|
|
9824: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
o;
|
|
if (
|
|
"Microsoft Internet Explorer" === navigator.appName ||
|
|
!!(
|
|
navigator.userAgent.match(/Trident/) ||
|
|
navigator.userAgent.match(/rv:11/)
|
|
) ||
|
|
(void 0 !== i.browser && 1 === i.browser.msie)
|
|
)
|
|
i(function () {
|
|
i(".u-social-icons, .u-language").each(function (t, e) {
|
|
var n = i(e),
|
|
size = n.css("height");
|
|
n.find(".u-svg-link").css("width", size);
|
|
});
|
|
});
|
|
},
|
|
9825: function (t, e, n) {
|
|
"use strict";
|
|
var Animation = n(9826),
|
|
i = n(189);
|
|
n(427), (window.uAnimation = new Animation(i.instance()).init());
|
|
},
|
|
9826: function (t, e, n) {
|
|
"use strict";
|
|
function Animation(factory) {
|
|
(this.factory = factory),
|
|
(this.animationElements = null),
|
|
(this.animationEvents = []),
|
|
(this._section = null),
|
|
(this._sliderNode = null),
|
|
(this._slideNumber = null),
|
|
(this._slideEvent = null),
|
|
(this._animationInfo = null),
|
|
(this._animation = null),
|
|
(this._subscribeQueue = []),
|
|
(this.status = "loading"),
|
|
(this._onDOMContentLoaded = this._onDOMContentLoaded.bind(this)),
|
|
(this._onLoadingComplete = this._onLoadingComplete.bind(this));
|
|
}
|
|
function i(t) {
|
|
var e =
|
|
window.requestAnimationFrame ||
|
|
window.mozRequestAnimationFrame ||
|
|
window.webkitRequestAnimationFrame ||
|
|
window.msRequestAnimationFrame;
|
|
if (!e) return t(), void 0;
|
|
e.apply(window, arguments);
|
|
}
|
|
function o(t) {
|
|
return (
|
|
"string" == typeof t.name && -1 !== m.indexOf(t.name.toLowerCase())
|
|
);
|
|
}
|
|
function a(t) {
|
|
return (
|
|
"string" == typeof t.direction &&
|
|
-1 !== v.indexOf(t.direction.toLowerCase())
|
|
);
|
|
}
|
|
function s(section, t) {
|
|
if (t && t.length)
|
|
if (u())
|
|
for (var e = 0; e < t.length; e++)
|
|
if (a(t[e]) || o(t[e])) {
|
|
section.style.overflow = "hidden";
|
|
break;
|
|
}
|
|
}
|
|
function u() {
|
|
return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(
|
|
navigator.userAgent || navigator.vendor || window.opera
|
|
);
|
|
}
|
|
var l = n(270),
|
|
f = n(271),
|
|
c = n(9827),
|
|
h = n(9828),
|
|
p = n(9829);
|
|
(Animation.utils = l),
|
|
(Animation.prototype.init = function init() {
|
|
if ("loading" !== document.readyState)
|
|
return this._onDOMContentLoaded(), void 0;
|
|
else
|
|
return (
|
|
document.addEventListener(
|
|
"DOMContentLoaded",
|
|
this._onDOMContentLoaded
|
|
),
|
|
this
|
|
);
|
|
}),
|
|
(Animation.prototype.start = function t() {
|
|
var e = this._subscribeQueue;
|
|
i(function () {
|
|
e.forEach(function (el) {
|
|
if (el.event && el.animation) el.event.subscribe(el.animation);
|
|
}),
|
|
(e.length = 0);
|
|
});
|
|
}),
|
|
(Animation.prototype.visitSection = function t(e) {
|
|
if (e.classList.contains("u-carousel"))
|
|
return this.visitSlider(e), void 0;
|
|
(this._section = e),
|
|
this._visitElementsInContentSlider(e),
|
|
this._visitElementsNotInSlider(e),
|
|
(this._section = null);
|
|
}),
|
|
(Animation.prototype._visitElementsInContentSlider = function (t) {
|
|
for (
|
|
var e = t.querySelectorAll(".u-carousel"), n = 0;
|
|
n < e.length;
|
|
n++
|
|
)
|
|
this.visitSlider(e[n]);
|
|
}),
|
|
(Animation.prototype._visitElementsNotInSlider = function (t) {
|
|
for (
|
|
var e = [], n = t.querySelectorAll("[data-animation-name]"), o = 0;
|
|
o < n.length;
|
|
o++
|
|
) {
|
|
var a = n[o];
|
|
if (
|
|
a.closest &&
|
|
null === a.closest(".u-carousel") &&
|
|
a.getAttribute("data-animation-name")
|
|
)
|
|
this.visitAnimatedElement(a),
|
|
e.push(this._animationInfo),
|
|
this._subscribeQueue.push({
|
|
animation: this._animation,
|
|
event: c,
|
|
}),
|
|
i(this._animation.init.bind(this._animation));
|
|
}
|
|
s(t, e);
|
|
}),
|
|
(Animation.prototype.visitSlider = function t(e) {
|
|
this._sliderNode = e;
|
|
for (
|
|
var n = e.querySelectorAll(".u-carousel-item"), i = 0;
|
|
i < n.length;
|
|
i++
|
|
)
|
|
(this._slideNumber = i), this.visitSlide(n[i]);
|
|
}),
|
|
(Animation.prototype.visitSlide = function t(e) {
|
|
var n = e.querySelectorAll("[data-animation-name]"),
|
|
i = [];
|
|
this._slideEvent = new h(this._sliderNode, e, this._slideNumber);
|
|
for (var o = 0; o < n.length; o++)
|
|
if (n[o].getAttribute("data-animation-name"))
|
|
this.visitAnimatedElement(n[o]),
|
|
i.push(this._animationInfo),
|
|
this._animation.init(),
|
|
this._slideEvent.animations.push(this._animation);
|
|
this._slideEvent.init(), s(e, i);
|
|
}),
|
|
(Animation.prototype.visitAnimatedElement = function t(e) {
|
|
(this._animationInfo = new f(e, this._section)),
|
|
(this._animation = this.factory.createAnimation(this._animationInfo)),
|
|
this.animationElements.push(this._animation);
|
|
}),
|
|
(Animation.prototype._onDOMContentLoaded = function () {
|
|
if (
|
|
((this.status = "DOMContentLoaded"),
|
|
document.removeEventListener(
|
|
"DOMContentLoaded",
|
|
this._onDOMContentLoaded
|
|
),
|
|
!this.animationElements)
|
|
) {
|
|
(this.animationElements = []), this.factory.setHint(p);
|
|
var sections = $("section, header, footer"),
|
|
length = sections.length;
|
|
if (
|
|
(sections.each(
|
|
function (index, t) {
|
|
if ((this.visitSection(t), !--length))
|
|
this.factory.setHint(null);
|
|
}.bind(this)
|
|
),
|
|
"interactive" !== document.readyState)
|
|
)
|
|
return this._onLoadingComplete(), void 0;
|
|
window.addEventListener("load", this._onLoadingComplete);
|
|
}
|
|
}),
|
|
(Animation.prototype._onLoadingComplete = function () {
|
|
(this.status = "complete"),
|
|
window.removeEventListener("load", this._onLoadingComplete),
|
|
this.start();
|
|
});
|
|
var m = ["lightspeedin", "flipin", "flipout"],
|
|
v = ["right", "downright", "upright"];
|
|
(t.exports = Animation), (window.Animation = Animation);
|
|
},
|
|
9827: function (t, e, n) {
|
|
"use strict";
|
|
function i(animation) {
|
|
if (
|
|
(animation.start(),
|
|
!animation.isInOutAnimation() && !animation.info.infinite)
|
|
) {
|
|
var t = animation.info.duration,
|
|
e = animation.info.delay;
|
|
setTimeout(function () {
|
|
animation.clear();
|
|
}, t + e);
|
|
}
|
|
}
|
|
function o(animation) {
|
|
if (animation.isInOutAnimation()) animation.startOut();
|
|
}
|
|
var a = {
|
|
subscribe: function t(animation) {
|
|
var e = (animation && animation.info) || {},
|
|
n = e.section || e.element;
|
|
animation.info.eventObject = new WaypointAdapter({
|
|
element: n,
|
|
handler: function (t) {
|
|
if (animation)
|
|
if ("up" === t) return o(animation), void 0;
|
|
else return i(animation), void 0;
|
|
},
|
|
offset: "70%",
|
|
});
|
|
},
|
|
};
|
|
(t.exports = a), (window.AnimationEventScroll = a);
|
|
},
|
|
9828: function (t, e, n) {
|
|
"use strict";
|
|
function i(carousel, slide, t) {
|
|
(this.carousel = $(carousel)),
|
|
(this.slide = $(slide)),
|
|
(this.slideNum = t),
|
|
(this.animations = []),
|
|
(this._delays = []),
|
|
(this._autoplayPaused = false),
|
|
(this._handleSlide = o.bind(this)),
|
|
(this._handleSlid = a.bind(this));
|
|
}
|
|
function o(t) {
|
|
if (t) if (t.from === this.slideNum) this.slideOut(t);
|
|
}
|
|
function a(t) {
|
|
if (t && t.to === this.slideNum)
|
|
this.pauseAutoplayWhileInAnimation(), this.startInAnimation();
|
|
}
|
|
(i.prototype.init = function init() {
|
|
if (
|
|
($(this.carousel).on("u-slide.bs.u-carousel", this._handleSlide),
|
|
$(this.carousel).on("slid.bs.u-carousel", this._handleSlid),
|
|
this.slide.is(".u-active"))
|
|
) {
|
|
if (this._isAutoplayOnStart()) this.pauseAutoplayWhileInAnimation();
|
|
this.startInAnimation();
|
|
}
|
|
}),
|
|
(i.prototype.deinit = function t() {
|
|
$(this.carousel).off("slid.bs.u-carousel", this._handleSlid),
|
|
$(this.carousel).off("u-slide.bs.u-carousel", this._handleSlide);
|
|
}),
|
|
(i.prototype.resetAnimations = function t() {
|
|
for (var e = 0; e < this.animations.length; e++)
|
|
if (this.animations[e].reset) this.animations[e].reset();
|
|
}),
|
|
(i.prototype.pauseAutoplayWhileInAnimation = function t() {
|
|
var e = this.countMaxInAnimationTime();
|
|
if (e > 0)
|
|
this._pauseAutoplay(),
|
|
this._delay(
|
|
e,
|
|
function () {
|
|
this._continueAutoplay(), this._clearDelays();
|
|
}.bind(this)
|
|
);
|
|
}),
|
|
(i.prototype.startInAnimation = function t() {
|
|
this.animations.forEach(
|
|
function (animation) {
|
|
animation.start();
|
|
}.bind(this)
|
|
);
|
|
}),
|
|
(i.prototype.needOutAnimation = function t() {
|
|
for (var e = 0, length = this.animations.length; e < length; e++)
|
|
if (
|
|
this.animations[e].needOutAnimation &&
|
|
this.animations[e].needOutAnimation()
|
|
)
|
|
return true;
|
|
return false;
|
|
}),
|
|
(i.prototype.startOutAnimations = function t() {
|
|
for (var e = 0; e < this.animations.length; e++)
|
|
if (this.animations[e].startOut) this.animations[e].startOut();
|
|
}),
|
|
(i.prototype.countMaxOutAnimationTime = function t() {
|
|
if (!this.animations || !this.animations.length) return 0;
|
|
var e = this.animations.map(function (animation) {
|
|
return animation.getOutTime();
|
|
});
|
|
return Math.max.apply(null, e);
|
|
}),
|
|
(i.prototype.countMaxInAnimationTime = function t() {
|
|
if (!this.animations || !this.animations.length) return 0;
|
|
var e = this.animations.map(function (animation) {
|
|
return animation.getTime();
|
|
});
|
|
return Math.max.apply(null, e);
|
|
}),
|
|
(i.prototype.slideOut = function t(e) {
|
|
if (this._delays.length > 0) this._cancelDelays();
|
|
if ((this._continueAutoplay(), !this.needOutAnimation()))
|
|
return this.resetAnimations(), void 0;
|
|
e.preventDefault();
|
|
var n = this.countMaxOutAnimationTime(),
|
|
i = "number" == typeof e.to ? e.to : null,
|
|
o = e.direction;
|
|
setTimeout(
|
|
function () {
|
|
if ((this.resetAnimations(), null !== i))
|
|
return $(e.target)["u-carousel"](i), void 0;
|
|
if ("left" === o) return $(e.target)["u-carousel"]("next"), void 0;
|
|
if ("right" === o) $(e.target)["u-carousel"]("prev");
|
|
}.bind(this),
|
|
n
|
|
),
|
|
this.startOutAnimations();
|
|
}),
|
|
(i.prototype._delay = function t(e, n) {
|
|
this._delays.push(
|
|
setTimeout(function () {
|
|
n();
|
|
}, e)
|
|
);
|
|
}),
|
|
(i.prototype._cancelDelays = function t() {
|
|
this._delays.forEach(function (id) {
|
|
clearTimeout(id);
|
|
}),
|
|
(this._delays.length = 0);
|
|
}),
|
|
(i.prototype._clearDelays = function t() {
|
|
this._delays.length = 0;
|
|
}),
|
|
(i.prototype._isAutoplayOnStart = function t() {
|
|
var e = this.carousel.attr("data-u-ride");
|
|
if (!e) return false;
|
|
else return "carousel" === (e = e.toLowerCase());
|
|
}),
|
|
(i.prototype._pauseAutoplay = function t() {
|
|
this.carousel["u-carousel"]("pause"), (this._autoplayPaused = true);
|
|
}),
|
|
(i.prototype._continueAutoplay = function t() {
|
|
if (this._autoplayPaused)
|
|
this.carousel["u-carousel"]("cycle"), (this._autoplayPaused = false);
|
|
}),
|
|
(t.exports = i),
|
|
(window.AnimationEventSlider = i);
|
|
},
|
|
9829: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
var e = [];
|
|
if (-1 !== a.indexOf(t.name) || t.direction) e.push("transform");
|
|
if (-1 !== s.indexOf(t.name)) e.push("opacity");
|
|
if (-1 !== u.indexOf(t.name)) e.push("contents");
|
|
if (0 === e.length) e.push("auto");
|
|
return e.join(", ");
|
|
}
|
|
var o = {},
|
|
a = [
|
|
"bounce",
|
|
"headShake",
|
|
"heartBeat",
|
|
"jello",
|
|
"pulse",
|
|
"rubberBand",
|
|
"shake",
|
|
"swing",
|
|
"tada",
|
|
"wobble",
|
|
"bounceIn",
|
|
"flip",
|
|
"flipInX",
|
|
"flipInY",
|
|
"flipOutX",
|
|
"flipOutY",
|
|
"lightSpeedIn",
|
|
"rotateIn",
|
|
"slideIn",
|
|
"hinge",
|
|
"jackInTheBox",
|
|
"rollIn",
|
|
"zoomIn",
|
|
"customAnimationIn",
|
|
"customAnimationOut",
|
|
],
|
|
s = [
|
|
"flash",
|
|
"bounceIn",
|
|
"fadeIn",
|
|
"flipInX",
|
|
"flipInY",
|
|
"flipOutX",
|
|
"flipOutY",
|
|
"lightSpeedIn",
|
|
"rotateIn",
|
|
"hinge",
|
|
"jackInTheBox",
|
|
"rollIn",
|
|
"zoomIn",
|
|
"customAnimationIn",
|
|
"customAnimationOut",
|
|
],
|
|
u = ["counter"];
|
|
(o.hintBrowser = function t(e) {
|
|
if (e && e.element) e.element.style.willChange = i(e);
|
|
}),
|
|
(o.removeHint = function t(e) {
|
|
e.element.style.willChange = "auto";
|
|
}),
|
|
(t.exports = o),
|
|
(window.WillChangeHint = o);
|
|
},
|
|
9830: function (t, e, n) {
|
|
"use strict";
|
|
function i() { }
|
|
function o(t, props) {
|
|
document.body.classList.add("u-scrollspy-prevent"),
|
|
t.animate(props, {
|
|
done: function () {
|
|
document.body.classList.remove("u-scrollspy-prevent");
|
|
},
|
|
});
|
|
}
|
|
var a = n(10);
|
|
(i.prototype.scroll = function (t) {
|
|
var e = 1,
|
|
n = a(".u-sticky")
|
|
.toArray()
|
|
.reduce(function (t, el) {
|
|
return t + (a(el).outerHeight(true) || 0) - e;
|
|
}, 0);
|
|
o(a("html, body"), { scrollTop: t.offset().top - n });
|
|
}),
|
|
(i.prototype.scrollTop = function () {
|
|
o(a("html, body"), { scrollTop: 0 });
|
|
}),
|
|
(i.prototype.update = function (t) {
|
|
var e = "string" == typeof t ? t : a(t.currentTarget).attr("href");
|
|
if ((e = (e || "").replace(/^[^#]+/, "")).match(/^#[\d\w-_]+$/i)) {
|
|
var n = a(e);
|
|
if (n.length) {
|
|
if (t.preventDefault) t.preventDefault();
|
|
this.scroll(n);
|
|
}
|
|
}
|
|
}),
|
|
(window._npScrollAnchor = new i()),
|
|
a(window).on("load", function () {
|
|
window._npScrollAnchor.update(window.location.hash),
|
|
a("body").on(
|
|
"click",
|
|
"a:not([data-u-slide], [data-u-slide-to], [data-toggle], .u-tab-link, .u-quantity-button)",
|
|
function (t) {
|
|
if (!a(this).is(".u-dialog-link"))
|
|
window._npScrollAnchor.update(t);
|
|
}
|
|
),
|
|
a("body").on("click", ".u-back-to-top", function () {
|
|
window._npScrollAnchor.scrollTop();
|
|
});
|
|
});
|
|
},
|
|
9831: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
o = n(9832),
|
|
a = "u-gdpr-cookie",
|
|
s = "u-cookies-consent",
|
|
u = "u-button-confirm",
|
|
l = "u-button-decline",
|
|
f = "_u_GDPRConfirmCode";
|
|
i(function () {
|
|
var t;
|
|
try {
|
|
t = o.get(a);
|
|
} catch (e) {
|
|
t = false;
|
|
}
|
|
var e = window[f] || function () { };
|
|
if (!t) {
|
|
var n = i("." + s);
|
|
n.addClass("show"),
|
|
n.find("." + u).on("click", function (t) {
|
|
t.preventDefault(),
|
|
o.set(a, true, { expires: 365, secure: true }),
|
|
n.removeClass("show"),
|
|
e();
|
|
}),
|
|
n.find("." + l).on("click", function (t) {
|
|
t.preventDefault(),
|
|
o.set(a, false, { expires: 365, secure: false }),
|
|
n.removeClass("show");
|
|
});
|
|
} else if ("true" === t) e();
|
|
});
|
|
},
|
|
9832: function (t, e, n) {
|
|
"use strict";
|
|
var i, o;
|
|
/*!
|
|
* JavaScript Cookie v2.2.1
|
|
* https://github.com/js-cookie/js-cookie
|
|
*
|
|
* Copyright 2006, 2015 Klaus Hartl & Fagner Brack
|
|
* Released under the MIT license
|
|
*/ !(function (factory) {
|
|
var a;
|
|
if (true)
|
|
!(
|
|
void 0 !==
|
|
(o = "function" == typeof (i = factory) ? i.call(e, n, e, t) : i) &&
|
|
(t.exports = o)
|
|
),
|
|
(a = true);
|
|
if (true) (t.exports = factory()), (a = true);
|
|
if (!a) {
|
|
var s = window.Cookies,
|
|
u = (window.Cookies = factory());
|
|
u.noConflict = function () {
|
|
return (window.Cookies = s), u;
|
|
};
|
|
}
|
|
})(function () {
|
|
function t() {
|
|
for (var t = 0, e = {}; t < arguments.length; t++) {
|
|
var n = arguments[t];
|
|
for (var i in n) e[i] = n[i];
|
|
}
|
|
return e;
|
|
}
|
|
function e(t) {
|
|
return t.replace(/(%[0-9A-Z]{2})+/g, decodeURIComponent);
|
|
}
|
|
function init(n) {
|
|
function i() { }
|
|
function o(e, o, a) {
|
|
if ("undefined" != typeof document) {
|
|
if (
|
|
"number" == typeof (a = t({ path: "/" }, i.defaults, a)).expires
|
|
)
|
|
a.expires = new Date(1 * new Date() + 864e5 * a.expires);
|
|
a.expires = a.expires ? a.expires.toUTCString() : "";
|
|
try {
|
|
var s = JSON.stringify(o);
|
|
if (/^[\{\[]/.test(s)) o = s;
|
|
} catch (t) { }
|
|
(o = n.write
|
|
? n.write(o, e)
|
|
: encodeURIComponent(String(o)).replace(
|
|
/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,
|
|
decodeURIComponent
|
|
)),
|
|
(e = encodeURIComponent(String(e))
|
|
.replace(/%(23|24|26|2B|5E|60|7C)/g, decodeURIComponent)
|
|
.replace(/[\(\)]/g, escape));
|
|
var u = "";
|
|
for (var l in a)
|
|
if (a[l])
|
|
if (((u += "; " + l), true !== a[l]))
|
|
u += "=" + a[l].split(";")[0];
|
|
return (document.cookie = e + "=" + o + u);
|
|
}
|
|
}
|
|
function a(t, i) {
|
|
if ("undefined" != typeof document) {
|
|
for (
|
|
var o = {},
|
|
a = document.cookie ? document.cookie.split("; ") : [],
|
|
s = 0;
|
|
s < a.length;
|
|
s++
|
|
) {
|
|
var u = a[s].split("="),
|
|
l = u.slice(1).join("=");
|
|
if (!i && '"' === l.charAt(0)) l = l.slice(1, -1);
|
|
try {
|
|
var f = e(u[0]);
|
|
if (((l = (n.read || n)(l, f) || e(l)), i))
|
|
try {
|
|
l = JSON.parse(l);
|
|
} catch (t) { }
|
|
if (((o[f] = l), t === f)) break;
|
|
} catch (t) { }
|
|
}
|
|
return t ? o[t] : o;
|
|
}
|
|
}
|
|
return (
|
|
(i.set = o),
|
|
(i.get = function (t) {
|
|
return a(t, false);
|
|
}),
|
|
(i.getJSON = function (t) {
|
|
return a(t, true);
|
|
}),
|
|
(i.remove = function (e, n) {
|
|
o(e, "", t(n, { expires: -1 }));
|
|
}),
|
|
(i.defaults = {}),
|
|
(i.withConverter = init),
|
|
i
|
|
);
|
|
}
|
|
return init(function () { });
|
|
});
|
|
},
|
|
9833: function (t, e, n) {
|
|
"use strict";
|
|
$(function () {
|
|
var selector = ".u-back-to-top";
|
|
$(selector).hide(),
|
|
$(window).scroll(function () {
|
|
if ($(this).scrollTop() > 100)
|
|
$(selector).fadeIn().css("display", "block");
|
|
else $(selector).fadeOut();
|
|
});
|
|
});
|
|
},
|
|
9834: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
o = n(9835);
|
|
(window._npScrollSpyInit = function () {
|
|
var t = '.u-menu .u-nav-container .u-nav-link[href*="#"]',
|
|
e = '.u-menu .u-nav-container-collapse .u-nav-link[href*="#"]',
|
|
n;
|
|
if (document.querySelectorAll(t).length)
|
|
try {
|
|
o(t, {
|
|
nested: true,
|
|
offset: function () {
|
|
var t, e;
|
|
return (i(".u-header.u-sticky").outerHeight(true) || 0) + 1;
|
|
},
|
|
}),
|
|
o(e, {
|
|
nested: true,
|
|
offset: function () {
|
|
return i(".u-header.u-sticky").outerHeight(true) || 0;
|
|
},
|
|
});
|
|
} catch (t) {
|
|
console.warn("ScrollSpy: has no items");
|
|
}
|
|
}),
|
|
document.addEventListener(
|
|
"gumshoeActivate",
|
|
function (t) {
|
|
var link;
|
|
t.detail.link.classList.add("active");
|
|
},
|
|
false
|
|
),
|
|
document.addEventListener(
|
|
"gumshoeDeactivate",
|
|
function (t) {
|
|
var link;
|
|
t.detail.link.classList.remove("active");
|
|
},
|
|
false
|
|
),
|
|
i(function () {
|
|
window._npScrollSpyInit();
|
|
});
|
|
},
|
|
9835: function (t, e, n) {
|
|
"use strict";
|
|
(function (n) {
|
|
var i, o;
|
|
/*!
|
|
* gumshoejs v5.1.2
|
|
* A simple, framework-agnostic scrollspy script.
|
|
* (c) 2019 Chris Ferdinandi
|
|
* MIT License
|
|
* http://github.com/cferdinandi/gumshoe
|
|
*/ !(function (n, factory) {
|
|
if (true)
|
|
!(
|
|
void 0 !==
|
|
(o = function () {
|
|
return factory(n);
|
|
}.apply(e, (i = []))) && (t.exports = o)
|
|
);
|
|
else if ("object" == typeof e) t.exports = factory(n);
|
|
else n.Gumshoe = factory(n);
|
|
})(
|
|
void 0 !== n ? n : "undefined" != typeof window ? window : this,
|
|
function (t) {
|
|
var e = {
|
|
navClass: "active",
|
|
contentClass: "active",
|
|
nested: false,
|
|
nestedClass: "active",
|
|
offset: 0,
|
|
reflow: false,
|
|
events: true,
|
|
},
|
|
n = function () {
|
|
var t = {};
|
|
return (
|
|
Array.prototype.forEach.call(arguments, function (e) {
|
|
for (var n in e) if (e.hasOwnProperty(n)) t[n] = e[n];
|
|
}),
|
|
t
|
|
);
|
|
},
|
|
i = function (type, t, e) {
|
|
if (e.settings.events) {
|
|
var n = new CustomEvent(type, {
|
|
bubbles: true,
|
|
cancelable: true,
|
|
detail: e,
|
|
});
|
|
t.dispatchEvent(n);
|
|
}
|
|
},
|
|
o = function (t) {
|
|
var e = 0;
|
|
if (t.offsetParent)
|
|
for (; t;) (e += t.offsetTop), (t = t.offsetParent);
|
|
return e >= 0 ? e : 0;
|
|
},
|
|
a = function (t) {
|
|
if (t)
|
|
t.sort(function (t, e) {
|
|
var n, i;
|
|
if (o(t.content) < o(e.content)) return -1;
|
|
else return 1;
|
|
});
|
|
},
|
|
s = function (settings) {
|
|
if ("function" == typeof settings.offset)
|
|
return parseFloat(settings.offset());
|
|
else return parseFloat(settings.offset);
|
|
},
|
|
u = function () {
|
|
return Math.max(
|
|
document.body.scrollHeight,
|
|
document.documentElement.scrollHeight,
|
|
document.body.offsetHeight,
|
|
document.documentElement.offsetHeight,
|
|
document.body.clientHeight,
|
|
document.documentElement.clientHeight
|
|
);
|
|
},
|
|
l = function (e, settings, n) {
|
|
var i = e.getBoundingClientRect(),
|
|
o = s(settings);
|
|
if (n)
|
|
return (
|
|
parseInt(i.bottom, 10) <
|
|
(t.innerHeight || document.documentElement.clientHeight)
|
|
);
|
|
else return parseInt(i.top, 10) <= o;
|
|
},
|
|
f = function () {
|
|
if (t.innerHeight + t.pageYOffset >= u()) return true;
|
|
else return false;
|
|
},
|
|
c = function (t, settings) {
|
|
if (f() && l(t.content, settings, true)) return true;
|
|
else return false;
|
|
},
|
|
h = function (t, settings) {
|
|
if (t.length) {
|
|
var e = t[t.length - 1];
|
|
if (c(e, settings)) return e;
|
|
for (var n = t.length - 1; n >= 0; n--)
|
|
if (l(t[n].content, settings)) return t[n];
|
|
}
|
|
},
|
|
p = function (nav, settings) {
|
|
if (settings.nested && nav.parentNode) {
|
|
var t = nav.parentNode.closest("li");
|
|
if (t) t.classList.remove(settings.nestedClass), p(t, settings);
|
|
}
|
|
},
|
|
m = function (items, settings) {
|
|
if (items) {
|
|
var t = items.nav.closest("li");
|
|
if (t)
|
|
t.classList.remove(settings.navClass),
|
|
items.content.classList.remove(settings.contentClass),
|
|
p(t, settings),
|
|
i("gumshoeDeactivate", t, {
|
|
link: items.nav,
|
|
content: items.content,
|
|
settings: settings,
|
|
});
|
|
}
|
|
},
|
|
v = function (nav, settings) {
|
|
if (settings.nested) {
|
|
var t = nav.parentNode.closest("li");
|
|
if (t) t.classList.add(settings.nestedClass), v(t, settings);
|
|
}
|
|
},
|
|
g = function (items, settings) {
|
|
if (items) {
|
|
var t = items.nav.closest("li");
|
|
if (t)
|
|
t.classList.add(settings.navClass),
|
|
items.content.classList.add(settings.contentClass),
|
|
v(t, settings),
|
|
i("gumshoeActivate", t, {
|
|
link: items.nav,
|
|
content: items.content,
|
|
settings: settings,
|
|
});
|
|
}
|
|
},
|
|
y;
|
|
return function (selector, i) {
|
|
var o = {},
|
|
s,
|
|
u,
|
|
l,
|
|
f,
|
|
settings;
|
|
(o.setup = function () {
|
|
(s = document.querySelectorAll(selector)),
|
|
(u = []),
|
|
Array.prototype.forEach.call(s, function (t) {
|
|
var e = document.getElementById(
|
|
decodeURIComponent(t.hash.substr(1))
|
|
);
|
|
if (e) u.push({ nav: t, content: e });
|
|
}),
|
|
a(u);
|
|
}),
|
|
(o.detect = function () {
|
|
if (!document.body.classList.contains("u-scrollspy-prevent")) {
|
|
var t = h(u, settings);
|
|
if (t) {
|
|
if (!l || t.content !== l.content)
|
|
m(l, settings), g(t, settings), (l = t);
|
|
} else if (l) m(l, settings), (l = null);
|
|
}
|
|
});
|
|
var c = function () {
|
|
if (f) t.cancelAnimationFrame(f);
|
|
f = t.requestAnimationFrame(o.detect);
|
|
},
|
|
p = function () {
|
|
if (f) t.cancelAnimationFrame(f);
|
|
f = t.requestAnimationFrame(function () {
|
|
a(u), o.detect();
|
|
});
|
|
},
|
|
init;
|
|
return (
|
|
(o.destroy = function () {
|
|
if (l) m(l, settings);
|
|
if (
|
|
(t.removeEventListener("scroll", c, false), settings.reflow)
|
|
)
|
|
t.removeEventListener("resize", p, false);
|
|
(u = null),
|
|
(s = null),
|
|
(l = null),
|
|
(f = null),
|
|
(settings = null);
|
|
}),
|
|
(function () {
|
|
if (
|
|
((settings = n(e, i || {})),
|
|
o.setup(),
|
|
o.detect(),
|
|
t.addEventListener("scroll", c, false),
|
|
settings.reflow)
|
|
)
|
|
t.addEventListener("resize", p, false);
|
|
})(),
|
|
o
|
|
);
|
|
};
|
|
}
|
|
);
|
|
}).call(e, n(41));
|
|
},
|
|
9836: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
o = n(9837),
|
|
HorizontalLayoutSlider = n(298);
|
|
i(window).on("load", function () {
|
|
setTimeout(function () {
|
|
i(".u-gallery").removeClass("u-no-transition"),
|
|
i(".u-layout-horizontal").each(function () {
|
|
var gallery = i(this),
|
|
slider = new HorizontalLayoutSlider(gallery, true);
|
|
gallery.children(".u-gallery-nav").click(function (t) {
|
|
t.preventDefault();
|
|
var e = i(t.currentTarget);
|
|
slider.navigate(e);
|
|
});
|
|
});
|
|
}, 250);
|
|
}),
|
|
i(function () {
|
|
var t;
|
|
i("body").on("mouseenter", ".u-gallery.u-no-transition", function () {
|
|
i(this).closest(".u-gallery").removeClass("u-no-transition");
|
|
}),
|
|
new o([
|
|
".u-gallery.u-product-zoom.u-layout-thumbnails",
|
|
".u-gallery.u-product-zoom.u-layout-carousel",
|
|
]).init();
|
|
});
|
|
},
|
|
9837: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
this.galleryZoomSelector = t;
|
|
}
|
|
function o(t) {
|
|
var e = t.currentTarget,
|
|
n,
|
|
i = u(e).closest(".u-gallery-item").data("zoom_click"),
|
|
o = e.getBoundingClientRect(),
|
|
a = e.querySelector("img"),
|
|
s = t.clientX,
|
|
l = t.clientY,
|
|
f = t.originalEvent.changedTouches;
|
|
if (!i && !f) {
|
|
u(e).addClass("hover");
|
|
var c = s - o.x,
|
|
h = l - o.y;
|
|
requestAnimationFrame(function () {
|
|
var t = c * (1 - a.offsetWidth / e.offsetWidth),
|
|
n = h * (1 - a.offsetHeight / e.offsetHeight);
|
|
(a.style.left = t + "px"), (a.style.top = n + "px");
|
|
});
|
|
}
|
|
}
|
|
function a(t) {
|
|
var e = u(t.currentTarget),
|
|
n;
|
|
u(e).removeClass("hover"),
|
|
u(e).closest(".u-gallery-item").data("zoom_click");
|
|
}
|
|
function s(t) {
|
|
var e = u(t.currentTarget);
|
|
u(e).removeClass("hover");
|
|
}
|
|
var u = n(10);
|
|
(t.exports = i),
|
|
(i.prototype.init = function () {
|
|
var t = this.galleryZoomSelector
|
|
.map(function (selector) {
|
|
return selector + " .u-back-slide";
|
|
})
|
|
.join(", "),
|
|
e = this.galleryZoomSelector
|
|
.map(function (selector) {
|
|
return selector + " .u-back-image";
|
|
})
|
|
.join(", ");
|
|
u("body").on("mousedown touchstart", t, a),
|
|
u("body").on("mousemove touchmove", t, o),
|
|
u("body").on("click mouseup mouseout touchend touchcancel", t, s),
|
|
u(e).each(function (t, e) {
|
|
var url = e.getAttribute("src");
|
|
u(e)
|
|
.parent()
|
|
.css("background-image", "url(" + url + ")");
|
|
});
|
|
}),
|
|
(window.ImageZoom = i);
|
|
},
|
|
9838: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
TabsControl = n(275);
|
|
(window._npTabsInit = function () {
|
|
function t(t) {
|
|
t.preventDefault(), t.stopPropagation();
|
|
var link = i(t.currentTarget),
|
|
tabsControl;
|
|
new TabsControl(link).show();
|
|
}
|
|
i("body").on("click", ".u-tab-link", t);
|
|
}),
|
|
i(function () {
|
|
window._npTabsInit();
|
|
});
|
|
},
|
|
9839: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(9840);
|
|
(window._npLazyImages = {
|
|
setup: function () {
|
|
(window.lazySizesConfig = window.lazySizesConfig || {}),
|
|
(window.lazySizesConfig.init = false),
|
|
document.addEventListener("lazybeforeunveil", function (t) {
|
|
var el = t.target;
|
|
if (el.matches("video")) {
|
|
var e = el.getAttribute("data-src"),
|
|
n = el.querySelector("source");
|
|
if (n && e) n.setAttribute("src", e);
|
|
} else {
|
|
var i = el.getAttribute("data-bg");
|
|
if (i) {
|
|
var list = cssBgParser.parseElementStyle(getComputedStyle(el));
|
|
if (list.backgrounds.length) list.backgrounds[0].color = "";
|
|
list.backgrounds.push(new cssBgParser.Background({ image: i })),
|
|
(el.style.backgroundImage = list.toString("image"));
|
|
}
|
|
}
|
|
});
|
|
},
|
|
init: function () {
|
|
i.init();
|
|
},
|
|
}),
|
|
window._npLazyImages.setup(),
|
|
$(function () {
|
|
window._npLazyImages.init();
|
|
});
|
|
},
|
|
9840: function (t, e, n) {
|
|
"use strict";
|
|
!(function (e, factory) {
|
|
var n = factory(e, e.document, Date);
|
|
if (((e.lazySizes = n), "object" == typeof t && t.exports)) t.exports = n;
|
|
})("undefined" != typeof window ? window : {}, function t(e, n, i) {
|
|
var o, a;
|
|
if (
|
|
(!(function () {
|
|
var t,
|
|
n = {
|
|
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: true,
|
|
expFactor: 1.5,
|
|
hFac: 0.8,
|
|
loadMode: 2,
|
|
loadHidden: true,
|
|
ricTimeout: 0,
|
|
throttleDelay: 125,
|
|
};
|
|
for (t in ((a = e.lazySizesConfig || e.lazysizesConfig || {}), n))
|
|
if (!(t in a)) a[t] = n[t];
|
|
})(),
|
|
!n || !n.getElementsByClassName)
|
|
)
|
|
return { init: function () { }, cfg: a, noSupport: true };
|
|
var s = n.documentElement,
|
|
u = e.HTMLPictureElement,
|
|
l = "addEventListener",
|
|
f = "getAttribute",
|
|
c = e[l].bind(e),
|
|
h = e.setTimeout,
|
|
p = e.requestAnimationFrame || h,
|
|
m = e.requestIdleCallback,
|
|
v = /^picture$/i,
|
|
g = ["load", "error", "lazyincluded", "_lazyloaded"],
|
|
y = {},
|
|
w = Array.prototype.forEach,
|
|
b = function (t, e) {
|
|
if (!y[e]) y[e] = new RegExp("(\\s|^)" + e + "(\\s|$)");
|
|
return y[e].test(t[f]("class") || "") && y[e];
|
|
},
|
|
C = function (t, e) {
|
|
if (!b(t, e))
|
|
t.setAttribute("class", (t[f]("class") || "").trim() + " " + e);
|
|
},
|
|
x = function (t, e) {
|
|
var n;
|
|
if ((n = b(t, e)))
|
|
t.setAttribute("class", (t[f]("class") || "").replace(n, " "));
|
|
},
|
|
S = function (t, e, add) {
|
|
var n = add ? l : "removeEventListener";
|
|
if (add) S(t, e);
|
|
g.forEach(function (i) {
|
|
t[n](i, e);
|
|
});
|
|
},
|
|
A = function (t, e, i, a, s) {
|
|
var u = n.createEvent("Event");
|
|
if (!i) i = {};
|
|
return (
|
|
(i.instance = o),
|
|
u.initEvent(e, !a, !s),
|
|
(u.detail = i),
|
|
t.dispatchEvent(u),
|
|
u
|
|
);
|
|
},
|
|
_ = function (el, t) {
|
|
var n;
|
|
if (!u && (n = e.picturefill || a.pf)) {
|
|
if (t && t.src && !el[f]("srcset"))
|
|
el.setAttribute("srcset", t.src);
|
|
n({ reevaluate: true, elements: [el] });
|
|
} else if (t && t.src) el.src = t.src;
|
|
},
|
|
T = function (t, style) {
|
|
return (getComputedStyle(t, null) || {})[style];
|
|
},
|
|
I = function (t, e, n) {
|
|
for (
|
|
n = n || t.offsetWidth;
|
|
n < a.minSize && e && !t._lazysizesWidth;
|
|
|
|
)
|
|
(n = e.offsetWidth), (e = e.parentNode);
|
|
return n;
|
|
},
|
|
E =
|
|
((B = []),
|
|
(O = L = []),
|
|
(F = function (t, e) {
|
|
if (k && !e) t.apply(this, arguments);
|
|
else if ((O.push(t), !M)) (M = true), (n.hidden ? h : p)(P);
|
|
}),
|
|
(F._lsFlush = P =
|
|
function () {
|
|
var t = O;
|
|
for (O = L.length ? B : L, k = true, M = false; t.length;)
|
|
t.shift()();
|
|
k = false;
|
|
}),
|
|
F),
|
|
k,
|
|
M,
|
|
L,
|
|
B,
|
|
O,
|
|
P,
|
|
F,
|
|
N = function (t, simple) {
|
|
return simple
|
|
? function () {
|
|
E(t);
|
|
}
|
|
: function () {
|
|
var e = this,
|
|
n = arguments;
|
|
E(function () {
|
|
t.apply(e, n);
|
|
});
|
|
};
|
|
},
|
|
z = function (t) {
|
|
var e,
|
|
n = 0,
|
|
o = a.throttleDelay,
|
|
s = a.ricTimeout,
|
|
u = function () {
|
|
(e = false), (n = i.now()), t();
|
|
},
|
|
l =
|
|
m && s > 49
|
|
? function () {
|
|
if ((m(u, { timeout: s }), s !== a.ricTimeout))
|
|
s = a.ricTimeout;
|
|
}
|
|
: N(function () {
|
|
h(u);
|
|
}, true);
|
|
return function (t) {
|
|
var a;
|
|
if ((t = true === t)) s = 33;
|
|
if (!e) {
|
|
if (((e = true), (a = o - (i.now() - n)) < 0)) a = 0;
|
|
if (t || a < 9) l();
|
|
else h(l, a);
|
|
}
|
|
};
|
|
},
|
|
U = function (t) {
|
|
var e,
|
|
n,
|
|
o = 99,
|
|
a = function () {
|
|
(e = null), t();
|
|
},
|
|
s = function () {
|
|
var t = i.now() - n;
|
|
if (t < o) h(s, o - t);
|
|
else (m || a)(a);
|
|
};
|
|
return function () {
|
|
if (((n = i.now()), !e)) e = h(s, o);
|
|
};
|
|
},
|
|
loader =
|
|
((nt = /^img$/i),
|
|
(rt = /^iframe$/i),
|
|
(ot = "onscroll" in e && !/(gle|ing)bot/.test(navigator.userAgent)),
|
|
(at = 0),
|
|
(st = 0),
|
|
(ut = 0),
|
|
(lt = -1),
|
|
(ft = function (t) {
|
|
if ((ut--, !t || ut < 0 || !t.target)) ut = 0;
|
|
}),
|
|
(ct = function (t) {
|
|
if (null == tt) tt = "hidden" == T(n.body, "visibility");
|
|
return (
|
|
tt ||
|
|
!(
|
|
"hidden" == T(t.parentNode, "visibility") &&
|
|
"hidden" == T(t, "visibility")
|
|
)
|
|
);
|
|
}),
|
|
(dt = function (t, e) {
|
|
var i,
|
|
o = t,
|
|
visible = ct(t);
|
|
for (
|
|
Z -= e, J += e, X -= e, K += e;
|
|
visible && (o = o.offsetParent) && o != n.body && o != s;
|
|
|
|
)
|
|
if (
|
|
(visible = (T(o, "opacity") || 1) > 0) &&
|
|
"visible" != T(o, "overflow")
|
|
)
|
|
(i = o.getBoundingClientRect()),
|
|
(visible =
|
|
K > i.left &&
|
|
X < i.right &&
|
|
J > i.top - 1 &&
|
|
Z < i.bottom + 1);
|
|
return visible;
|
|
}),
|
|
(pt = z(
|
|
(ht = function () {
|
|
var t,
|
|
e,
|
|
rect,
|
|
i,
|
|
u,
|
|
l,
|
|
c,
|
|
h,
|
|
p,
|
|
m,
|
|
v,
|
|
g,
|
|
y = o.elements;
|
|
if ((Y = a.loadMode) && ut < 8 && (t = y.length)) {
|
|
for (e = 0, lt++; e < t; e++)
|
|
if (y[e] && !y[e]._lazyRace)
|
|
if (
|
|
!(!ot || (o.prematureUnveil && o.prematureUnveil(y[e])))
|
|
) {
|
|
if (!(h = y[e][f]("data-expand")) || !(l = 1 * h)) l = st;
|
|
if (!m)
|
|
if (
|
|
((m =
|
|
!a.expand || a.expand < 1
|
|
? s.clientHeight > 500 && s.clientWidth > 500
|
|
? 500
|
|
: 370
|
|
: a.expand),
|
|
(o._defEx = m),
|
|
(v = m * a.expFactor),
|
|
(g = a.hFac),
|
|
(tt = null),
|
|
st < v && ut < 1 && lt > 2 && Y > 2 && !n.hidden)
|
|
)
|
|
(st = v), (lt = 0);
|
|
else if (Y > 1 && lt > 1 && ut < 6) st = m;
|
|
else st = at;
|
|
if (p !== l)
|
|
(j = innerWidth + l * g),
|
|
(G = innerHeight + l),
|
|
(c = -1 * l),
|
|
(p = l);
|
|
if (
|
|
((rect = y[e].getBoundingClientRect()),
|
|
(J = rect.bottom) >= c &&
|
|
(Z = rect.top) <= G &&
|
|
(K = rect.right) >= c * g &&
|
|
(X = rect.left) <= j &&
|
|
(J || K || X || Z) &&
|
|
(a.loadHidden || ct(y[e])) &&
|
|
(($ && ut < 3 && !h && (Y < 3 || lt < 4)) ||
|
|
dt(y[e], l)))
|
|
) {
|
|
if ((Ct(y[e]), (u = true), ut > 9)) break;
|
|
} else if (
|
|
!u &&
|
|
$ &&
|
|
!i &&
|
|
ut < 4 &&
|
|
lt < 4 &&
|
|
Y > 2 &&
|
|
(H[0] || a.preloadAfterLoad) &&
|
|
(H[0] ||
|
|
(!h &&
|
|
(J ||
|
|
K ||
|
|
X ||
|
|
Z ||
|
|
"auto" != y[e][f](a.sizesAttr))))
|
|
)
|
|
i = H[0] || y[e];
|
|
} else Ct(y[e]);
|
|
if (i && !u) Ct(i);
|
|
}
|
|
})
|
|
)),
|
|
(vt = N(
|
|
(mt = function (t) {
|
|
var e = t.target;
|
|
if (e._lazyCache) return delete e._lazyCache, void 0;
|
|
ft(t),
|
|
C(e, a.loadedClass),
|
|
x(e, a.loadingClass),
|
|
S(e, gt),
|
|
A(e, "lazyloaded");
|
|
})
|
|
)),
|
|
(gt = function (t) {
|
|
vt({ target: t.target });
|
|
}),
|
|
(yt = function (t, e) {
|
|
try {
|
|
t.contentWindow.location.replace(e);
|
|
} catch (n) {
|
|
t.src = e;
|
|
}
|
|
}),
|
|
(wt = function (t) {
|
|
var e,
|
|
n = t[f](a.srcsetAttr);
|
|
if ((e = a.customMedia[t[f]("data-media") || t[f]("media")]))
|
|
t.setAttribute("media", e);
|
|
if (n) t.setAttribute("srcset", n);
|
|
}),
|
|
(bt = N(function (t, e, n, i, o) {
|
|
var s, u, l, c, p, m;
|
|
if (!(p = A(t, "lazybeforeunveil", e)).defaultPrevented) {
|
|
if (i)
|
|
if (n) C(t, a.autosizesClass);
|
|
else t.setAttribute("sizes", i);
|
|
if (((u = t[f](a.srcsetAttr)), (s = t[f](a.srcAttr)), o))
|
|
c = (l = t.parentNode) && v.test(l.nodeName || "");
|
|
if (
|
|
((m = e.firesLoad || ("src" in t && (u || s || c))),
|
|
(p = { target: t }),
|
|
C(t, a.loadingClass),
|
|
m)
|
|
)
|
|
clearTimeout(V), (V = h(ft, 2500)), S(t, gt, true);
|
|
if (c) w.call(l.getElementsByTagName("source"), wt);
|
|
if (u) t.setAttribute("srcset", u);
|
|
else if (s && !c)
|
|
if (rt.test(t.nodeName)) yt(t, s);
|
|
else t.src = s;
|
|
if (o && (u || c)) _(t, { src: s });
|
|
}
|
|
if (t._lazyRace) delete t._lazyRace;
|
|
x(t, a.lazyClass),
|
|
E(function () {
|
|
var e = t.complete && t.naturalWidth > 1;
|
|
if (!m || e) {
|
|
if (e) C(t, "ls-is-cached");
|
|
mt(p),
|
|
(t._lazyCache = true),
|
|
h(function () {
|
|
if ("_lazyCache" in t) delete t._lazyCache;
|
|
}, 9);
|
|
}
|
|
if ("lazy" == t.loading) ut--;
|
|
}, true);
|
|
})),
|
|
(Ct = function (t) {
|
|
if (!t._lazyRace) {
|
|
var e,
|
|
n = nt.test(t.nodeName),
|
|
i = n && (t[f](a.sizesAttr) || t[f]("sizes")),
|
|
o = "auto" == i;
|
|
if (
|
|
(!o && $) ||
|
|
!n ||
|
|
(!t[f]("src") && !t.srcset) ||
|
|
t.complete ||
|
|
b(t, a.errorClass) ||
|
|
!b(t, a.lazyClass)
|
|
) {
|
|
if (((e = A(t, "lazyunveilread").detail), o))
|
|
_t.updateElem(t, true, t.offsetWidth);
|
|
(t._lazyRace = true), ut++, bt(t, e, o, i, n);
|
|
}
|
|
}
|
|
}),
|
|
(xt = U(function () {
|
|
(a.loadMode = 3), pt();
|
|
})),
|
|
(At = function () {
|
|
if (!$) {
|
|
if (i.now() - W < 999) return h(At, 999), void 0;
|
|
($ = true), (a.loadMode = 3), pt(), c("scroll", St, true);
|
|
}
|
|
}),
|
|
{
|
|
_: function () {
|
|
if (
|
|
((W = i.now()),
|
|
(o.elements = n.getElementsByClassName(a.lazyClass)),
|
|
(H = n.getElementsByClassName(
|
|
a.lazyClass + " " + a.preloadClass
|
|
)),
|
|
c("scroll", pt, true),
|
|
c("resize", pt, true),
|
|
c("pageshow", function (t) {
|
|
if (t.persisted) {
|
|
var e = n.querySelectorAll("." + a.loadingClass);
|
|
if (e.length && e.forEach)
|
|
p(function () {
|
|
e.forEach(function (t) {
|
|
if (t.complete) Ct(t);
|
|
});
|
|
});
|
|
}
|
|
}),
|
|
e.MutationObserver)
|
|
)
|
|
new MutationObserver(pt).observe(s, {
|
|
childList: true,
|
|
subtree: true,
|
|
attributes: true,
|
|
});
|
|
else
|
|
s[l]("DOMNodeInserted", pt, true),
|
|
s[l]("DOMAttrModified", pt, true),
|
|
setInterval(pt, 999);
|
|
if (
|
|
(c("hashchange", pt, true),
|
|
[
|
|
"focus",
|
|
"mouseover",
|
|
"click",
|
|
"load",
|
|
"transitionend",
|
|
"animationend",
|
|
].forEach(function (t) {
|
|
n[l](t, pt, true);
|
|
}),
|
|
/d$|^c/.test(n.readyState))
|
|
)
|
|
At();
|
|
else c("load", At), n[l]("DOMContentLoaded", pt), h(At, 2e4);
|
|
if (o.elements.length) ht(), E._lsFlush();
|
|
else pt();
|
|
},
|
|
checkElems: pt,
|
|
unveil: Ct,
|
|
_aLSL: (St = function () {
|
|
if (3 == a.loadMode) a.loadMode = 2;
|
|
xt();
|
|
}),
|
|
}),
|
|
H,
|
|
$,
|
|
V,
|
|
Y,
|
|
W,
|
|
j,
|
|
G,
|
|
Z,
|
|
X,
|
|
K,
|
|
J,
|
|
tt,
|
|
nt,
|
|
rt,
|
|
ot,
|
|
at,
|
|
st,
|
|
ut,
|
|
lt,
|
|
ft,
|
|
ct,
|
|
dt,
|
|
ht,
|
|
pt,
|
|
mt,
|
|
vt,
|
|
gt,
|
|
yt,
|
|
wt,
|
|
bt,
|
|
Ct,
|
|
xt,
|
|
St,
|
|
At,
|
|
_t =
|
|
((Dt = N(function (t, e, n, i) {
|
|
var o, a, s;
|
|
if (
|
|
((t._lazysizesWidth = i),
|
|
(i += "px"),
|
|
t.setAttribute("sizes", i),
|
|
v.test(e.nodeName || ""))
|
|
)
|
|
for (
|
|
a = 0, s = (o = e.getElementsByTagName("source")).length;
|
|
a < s;
|
|
a++
|
|
)
|
|
o[a].setAttribute("sizes", i);
|
|
if (!n.detail.dataAttr) _(t, n.detail);
|
|
})),
|
|
(kt = function (t, e, n) {
|
|
var i,
|
|
o = t.parentNode;
|
|
if (o)
|
|
if (
|
|
((n = I(t, o, n)),
|
|
!(i = A(t, "lazybeforesizes", { width: n, dataAttr: !!e }))
|
|
.defaultPrevented)
|
|
)
|
|
if ((n = i.detail.width) && n !== t._lazysizesWidth)
|
|
Dt(t, o, i, n);
|
|
}),
|
|
{
|
|
_: function () {
|
|
(Tt = n.getElementsByClassName(a.autosizesClass)),
|
|
c("resize", Lt);
|
|
},
|
|
checkElems: (Lt = U(function () {
|
|
var t,
|
|
e = Tt.length;
|
|
if (e) for (t = 0; t < e; t++) kt(Tt[t]);
|
|
})),
|
|
updateElem: kt,
|
|
}),
|
|
Tt,
|
|
Dt,
|
|
kt,
|
|
Mt,
|
|
Lt,
|
|
init = function () {
|
|
if (!init.i && n.getElementsByClassName)
|
|
(init.i = true), _t._(), loader._();
|
|
};
|
|
return (
|
|
h(function () {
|
|
if (a.init) init();
|
|
}),
|
|
(o = {
|
|
cfg: a,
|
|
autoSizer: _t,
|
|
loader: loader,
|
|
init: init,
|
|
uP: _,
|
|
aC: C,
|
|
rC: x,
|
|
hC: b,
|
|
fire: A,
|
|
gW: I,
|
|
rAF: E,
|
|
})
|
|
);
|
|
});
|
|
},
|
|
9841: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
Dialog = n(195);
|
|
(window._npDialogsInit = function () {
|
|
function t(t) {
|
|
var dialog;
|
|
t.preventDefault(), t.stopPropagation(), n(t).open();
|
|
}
|
|
function e(t) {
|
|
var dialog;
|
|
t.preventDefault(), t.stopPropagation(), n(t).close();
|
|
}
|
|
function n(t) {
|
|
var link = i(t.currentTarget),
|
|
e = link.attr("href") || link.attr("data-href"),
|
|
n = i(e);
|
|
return (n = n.length ? n : link), new Dialog(n);
|
|
}
|
|
function o() {
|
|
return new Dialog(i('[data-dialog-show-on="page_exit"]'));
|
|
}
|
|
function a() {
|
|
return new Dialog(i('[data-dialog-show-on="timer"]'));
|
|
}
|
|
function s(t) {
|
|
if (
|
|
t.clientY < 50 &&
|
|
null == t.relatedTarget &&
|
|
"select" !== t.target.nodeName.toLowerCase()
|
|
) {
|
|
var dialog;
|
|
o().open(function () {
|
|
document.removeEventListener("mouseout", s);
|
|
});
|
|
}
|
|
}
|
|
function u() {
|
|
var dialog = a();
|
|
setTimeout(function () {
|
|
dialog.open();
|
|
}, dialog.getInterval());
|
|
}
|
|
function l(t) {
|
|
var e = i(t.currentTarget);
|
|
setTimeout(function () {
|
|
new Dialog(e).close();
|
|
});
|
|
}
|
|
i("body").on("click", ".u-dialog-link", t),
|
|
i("body").on("click", ".u-dialog-close-button", e),
|
|
i("body").on("click", ".u-dialog .u-btn:not(.u-btn-step)", l),
|
|
document.addEventListener("mouseout", s),
|
|
u();
|
|
}),
|
|
i(function () {
|
|
window._npDialogsInit();
|
|
});
|
|
},
|
|
9842: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
CountdownUpdater = n(191);
|
|
i(window).on("load", function () {
|
|
function update() {
|
|
t.each(function (t, el) {
|
|
var countdownUpdater;
|
|
new CountdownUpdater(i(el)).startUpdate("runtime");
|
|
});
|
|
}
|
|
var t = CountdownUpdater.findAll();
|
|
if (t.length) update();
|
|
});
|
|
},
|
|
9843: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(function () {
|
|
i(document).on("click", ".u-quantity-input a", function (t) {
|
|
var e;
|
|
t.preventDefault();
|
|
var n = i(this),
|
|
o = n.siblings("input");
|
|
if (n.hasClass("minus"))
|
|
(e = (e = parseFloat(o.val()) - 1) < 1 ? 1 : e), o.val(e);
|
|
if (n.hasClass("plus")) (e = parseFloat(o.val()) + 1), o.val(e);
|
|
n
|
|
.siblings(".minus")
|
|
.addBack(".minus")
|
|
.toggleClass("disabled", 1 === e),
|
|
o.change();
|
|
});
|
|
});
|
|
},
|
|
9844: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
Accordion = n(160);
|
|
(window._npAccordionInit = function () {
|
|
function t(t) {
|
|
t.preventDefault(), t.stopPropagation();
|
|
var link = i(t.currentTarget),
|
|
accordion;
|
|
new Accordion(link).show();
|
|
}
|
|
i("body").on("click", ".u-accordion-link", t);
|
|
}),
|
|
i(function () {
|
|
window._npAccordionInit();
|
|
});
|
|
},
|
|
9845: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
t.preventDefault(), t.stopPropagation();
|
|
var form = l(this),
|
|
password;
|
|
a(form.find("input[name=password]").val() || "", function () {
|
|
s(form);
|
|
});
|
|
}
|
|
function o() {
|
|
a(localStorage.getItem(f)), l("#password-redirect-style").remove();
|
|
}
|
|
function a(password, t) {
|
|
if (password) {
|
|
var e = l("body"),
|
|
n = e.attr("data-salt"),
|
|
i = e.attr("data-salted-password"),
|
|
hash = u.create().update(password).digest().toHex(),
|
|
o = u
|
|
.create()
|
|
.update(password + n)
|
|
.digest()
|
|
.toHex(),
|
|
homePage,
|
|
url = (e.attr("data-home-page") || window.location.pathname).replace(
|
|
/\.html(\?[\s\S]*)?$/,
|
|
"_" + hash + ".html$1"
|
|
);
|
|
if (o === i)
|
|
localStorage.setItem(f, password), window.location.replace(url);
|
|
else if ("function" == typeof t) t();
|
|
}
|
|
}
|
|
function s(form) {
|
|
var t = form.find(".u-form-send-error");
|
|
t.show(),
|
|
setTimeout(function () {
|
|
t.hide();
|
|
}, 2e3);
|
|
}
|
|
var u = n(180),
|
|
l = n(10),
|
|
f = "auth_key";
|
|
(window.sha256 = u),
|
|
(window._npAuthInit = function () {
|
|
var form = l(".u-password-control form"),
|
|
t = form.find("input[name=password_hash]");
|
|
if (t.length)
|
|
form.find(".u-form-submit a").click(function (e) {
|
|
e.preventDefault(), e.stopPropagation();
|
|
var password = form.find("input[name=password]").val() || "",
|
|
hash = u.create().update(password).digest().toHex();
|
|
t.val(hash), l(this).closest("form").find(":submit").click();
|
|
});
|
|
else form.submit(i);
|
|
}),
|
|
l(function () {
|
|
window._npAuthInit(), o();
|
|
});
|
|
},
|
|
9846: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(function () {
|
|
i("body").on("click", ".u-language-active", function (t) {
|
|
t.preventDefault();
|
|
});
|
|
});
|
|
},
|
|
9847: function (t, e, n) {
|
|
"use strict";
|
|
var FormRating = (t.exports = {}),
|
|
i = n(10),
|
|
o = ".u-form-rating-item:visible";
|
|
i(function () {
|
|
FormRating.init();
|
|
}),
|
|
(FormRating.selectStars = function t(e, n) {
|
|
var o = e.find(".u-active-icon"),
|
|
a = e.find(".u-passive-icon"),
|
|
s = o.length;
|
|
o.hide(),
|
|
a.hide(),
|
|
i(o.toArray().slice(0, n)).show(),
|
|
i(a.toArray().slice(0, s - n)).show();
|
|
}),
|
|
(FormRating.onStarClick = function t(e) {
|
|
var n = i(e.currentTarget),
|
|
a = n.parents(".u-form-rating").find("input"),
|
|
s,
|
|
u = n.prevAll(o).length + 1,
|
|
l = a.val() + "";
|
|
if (u.toString() === l) return a.val(""), void 0;
|
|
a.val(u);
|
|
}),
|
|
(FormRating.onStarHover = function t(e) {
|
|
var n = i(e.currentTarget),
|
|
a = n.prevAll(o);
|
|
FormRating.selectStars(n.parent(), a.length + 1);
|
|
}),
|
|
(FormRating.onLeave = function t(e) {
|
|
var n = i(e.currentTarget),
|
|
o,
|
|
a = n.find("input").val() || 0;
|
|
FormRating.selectStars(n, a);
|
|
}),
|
|
(FormRating.init = function init() {
|
|
var t = ".u-form .u-form-rating .u-form-rating-item",
|
|
e = i(".u-form .u-form-rating");
|
|
FormRating.onLeave({ currentTarget: e }),
|
|
e.mouseleave(FormRating.onLeave),
|
|
i(t).hover(FormRating.onStarHover),
|
|
i(t).click(FormRating.onStarClick);
|
|
var n = e.find("input[type=hidden][required]");
|
|
if (n && n.length) n.addClass("u-input-hidden"), n.attr("type", "text");
|
|
});
|
|
},
|
|
9848: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(function () {
|
|
i("body").on("click", ".u-form .u-gallery-item", function (t) {
|
|
if (!i(t.target).is("input, label")) {
|
|
var input = i(this).find("input");
|
|
input.prop("checked", !input.prop("checked"));
|
|
}
|
|
});
|
|
});
|
|
},
|
|
9849: function (t, e, n) {
|
|
"use strict";
|
|
function i(input) {
|
|
var t = parseFloat(input.prop("max")),
|
|
e = parseFloat(input.prop("min")),
|
|
n = parseFloat(input.prop("value")),
|
|
i = 0;
|
|
if (n) i = (100 * (n - e)) / (t - e);
|
|
var formField = input.closest(".u-form-number");
|
|
if (formField.length)
|
|
formField[0].style.setProperty("--progress", i + "%");
|
|
}
|
|
function o(t, e) {
|
|
if (e.length && t.length)
|
|
e.prop("value", t.prop("value")), e.trigger("change");
|
|
}
|
|
function a(t) {
|
|
if (t.length) {
|
|
var e = t.prop("value");
|
|
t.closest(".u-input-row").attr("data-value", e);
|
|
}
|
|
}
|
|
var s = n(10);
|
|
s(function () {
|
|
var t = s("body");
|
|
t.on("input", '.u-form .u-form-number input[type="range"]', function () {
|
|
var input = s(this),
|
|
t = input.siblings("input");
|
|
if (t.length) o(input, t);
|
|
i(input), a(input);
|
|
}),
|
|
t.on(
|
|
"input",
|
|
'.u-form .u-form-number input[type="number"]',
|
|
function () {
|
|
var input = s(this),
|
|
t = input.siblings("input");
|
|
if (t.length) o(input, t), i(t);
|
|
a(input);
|
|
}
|
|
);
|
|
});
|
|
},
|
|
9850: function (t, e, n) {
|
|
"use strict";
|
|
function i(t, dependency) {
|
|
var e = [
|
|
'[name="' + dependency.field + '"]',
|
|
'[name="' + dependency.field + '[]"]',
|
|
].join(", "),
|
|
n = t.find(e);
|
|
if (!n.length) return false;
|
|
if (!(dependency.condition in f)) return false;
|
|
else return f[dependency.condition](n, dependency.value);
|
|
}
|
|
function o(t, e) {
|
|
if (e in l) l[e](t);
|
|
}
|
|
function a(t) {
|
|
return t
|
|
.toArray()
|
|
.filter(function (el) {
|
|
return el.checked;
|
|
})
|
|
.map(function (el) {
|
|
var t = el.value;
|
|
if (!t) t = el.getAttribute("data-calc") || "";
|
|
return String(t).trim();
|
|
});
|
|
}
|
|
function s(t, e) {
|
|
return String(t).trim() === String(e).trim();
|
|
}
|
|
var FormDependency = (t.exports = {}),
|
|
u = n(10);
|
|
u(function () {
|
|
u(".u-form").each(function () {
|
|
FormDependency.process(u(this));
|
|
});
|
|
var t = function () {
|
|
FormDependency.process(u(this).closest(".u-form"));
|
|
};
|
|
u("body")
|
|
.on("input", ".u-form input[name], .u-form input[name]", t)
|
|
.on("change", ".u-form input[name], .u-form select[name]", t);
|
|
}),
|
|
(FormDependency.process = function t(e) {
|
|
e.find("[data-dependency]").each(function () {
|
|
var t = u(this),
|
|
dependency;
|
|
try {
|
|
dependency = JSON.parse(t.attr("data-dependency"))[0];
|
|
} catch (t) {
|
|
dependency = null;
|
|
}
|
|
if (dependency)
|
|
if (i(e, dependency)) o(t, dependency.action);
|
|
else {
|
|
var n;
|
|
o(t, { hide: "show", show: "hide" }[dependency.action]);
|
|
}
|
|
});
|
|
});
|
|
var l = {
|
|
show: function (t) {
|
|
t.closest(".u-form-group").show();
|
|
},
|
|
hide: function (t) {
|
|
t.closest(".u-form-group").hide();
|
|
},
|
|
},
|
|
f = {
|
|
equal: function (t, e) {
|
|
if (t.is('input[type="checkbox"], input[type="radio"]'))
|
|
return this.has.apply(this, arguments);
|
|
else return s(t.val(), e);
|
|
},
|
|
"not-equal": function () {
|
|
return !this.equal.apply(this, arguments);
|
|
},
|
|
contain: function (t, e) {
|
|
if (t.is('input[type="checkbox"], input[type="radio"]')) {
|
|
var n;
|
|
return a(t).some(function (t) {
|
|
return String(t).includes(e);
|
|
}, this);
|
|
}
|
|
return String(t.val()).includes(e);
|
|
},
|
|
"not-contain": function () {
|
|
return !this.contain.apply(this, arguments);
|
|
},
|
|
has: function (t, e) {
|
|
return a(t).includes(String(e).trim());
|
|
},
|
|
"not-has": function () {
|
|
return !this.has.apply(this, arguments);
|
|
},
|
|
"number-equal": function (t, e) {
|
|
var n = parseFloat(t.val());
|
|
if (n === (e = parseFloat(e))) return true;
|
|
var diff = Math.abs(n - e),
|
|
i;
|
|
if (diff < Number.EPSILON) return true;
|
|
else
|
|
return diff <= Math.min(Math.abs(n), Math.abs(e)) * Number.EPSILON;
|
|
},
|
|
"number-not-equal": function () {
|
|
return this["="].apply(this, arguments);
|
|
},
|
|
"number-greater": function (t, e) {
|
|
var n;
|
|
return parseFloat(t.val()) > (e = parseFloat(e));
|
|
},
|
|
"number-greater-or-equal": function () {
|
|
return (
|
|
this[">"].apply(this, arguments) || this["="].apply(this, arguments)
|
|
);
|
|
},
|
|
"number-less": function (t, e) {
|
|
var n;
|
|
return parseFloat(t.val()) < (e = parseFloat(e));
|
|
},
|
|
"number-less-or-equal": function () {
|
|
return (
|
|
this["<"].apply(this, arguments) || this["="].apply(this, arguments)
|
|
);
|
|
},
|
|
};
|
|
},
|
|
9851: function (t, e, n) {
|
|
"use strict";
|
|
function i(form) {
|
|
var activeSlide, t;
|
|
return form
|
|
.find(".u-slide.active, .u-slide.u-active")
|
|
.find("input, textarea, select")
|
|
.toArray()
|
|
.every(function (input) {
|
|
return input.reportValidity();
|
|
});
|
|
}
|
|
var o = n(10),
|
|
FormProgress = n(487),
|
|
a = n(488),
|
|
s = "u-carousel";
|
|
o(function () {
|
|
var t = o("body"),
|
|
e = o(".u-form.u-carousel");
|
|
e.find(".u-carousel-inner").css("overflow", "unset"),
|
|
a.update(e),
|
|
FormProgress.update(e),
|
|
t.on("click", ".u-btn-step", function (t) {
|
|
t.preventDefault();
|
|
var button = o(this),
|
|
e = button.closest(".u-carousel");
|
|
if (e.length)
|
|
if (button.hasClass("u-btn-step-next")) e[s]("next");
|
|
else if (button.hasClass("u-btn-step-prev")) e[s]("prev");
|
|
}),
|
|
e
|
|
.on("u-slide.bs.u-carousel", function (t) {
|
|
var form = o(this);
|
|
if (0 !== t.to && t.to > t.from && !i(form))
|
|
return t.preventDefault(), void 0;
|
|
a.update(o(this), t.to),
|
|
FormProgress.update(o(this), t.to),
|
|
form.find(".u-carousel-inner").css("overflow", "");
|
|
})
|
|
.on("slid.bs.u-carousel", function () {
|
|
var form;
|
|
o(this).find(".u-carousel-inner").css("overflow", "unset");
|
|
})
|
|
.on("reset", function () {
|
|
o(this)[s]("to", 0);
|
|
});
|
|
});
|
|
},
|
|
9852: function (t, e, n) {
|
|
"use strict";
|
|
function i() {
|
|
return (
|
|
-1 !== (u("html").attr("class") || "").search(/u-responsive-(xs|sm)/)
|
|
);
|
|
}
|
|
function o() {
|
|
var t = 0;
|
|
if (
|
|
Intl &&
|
|
Intl.Locale &&
|
|
navigator.language &&
|
|
new Intl.Locale(navigator.language).weekInfo
|
|
)
|
|
t = new Intl.Locale(navigator.language).weekInfo.firstDay || 0;
|
|
return t;
|
|
}
|
|
var a = n(9853),
|
|
s = n(9854),
|
|
u = n(10),
|
|
l = {
|
|
init: function (el) {
|
|
if (i()) return l.switchToDate(el), null;
|
|
else return l.create(el);
|
|
},
|
|
create: function (el) {
|
|
return (
|
|
l.switchToText(el),
|
|
a(el, {
|
|
formatter: function (input, t) {
|
|
var format = input.getAttribute("data-date-format");
|
|
if ("local" === format && Intl && Intl.DateTimeFormat)
|
|
t = Intl.DateTimeFormat().format(t);
|
|
else t = s(t, format || "default");
|
|
input.setAttribute("value", t);
|
|
},
|
|
startDay: o(),
|
|
})
|
|
);
|
|
},
|
|
remove: function (el, t) {
|
|
if (t) t.remove();
|
|
l.switchToDate(el);
|
|
},
|
|
switchToDate: function (el) {
|
|
el.removeAttribute("value"),
|
|
el.removeAttribute("readonly"),
|
|
(el.type = "date");
|
|
},
|
|
switchToText: function (el) {
|
|
el.setAttribute("readonly", "readonly"), (el.type = "text");
|
|
},
|
|
};
|
|
u(function () {
|
|
var selector;
|
|
u("form input[data-date-format]").each(function () {
|
|
var t = l.init(this);
|
|
u(this).focus(function (e) {
|
|
var n = e.target;
|
|
if (!i()) {
|
|
if (!t) t = l.create(n);
|
|
} else if (t) l.remove(n, t), (t = null);
|
|
});
|
|
});
|
|
});
|
|
},
|
|
9853: function (t, e, n) {
|
|
"use strict";
|
|
var i, o;
|
|
(i = window),
|
|
(o = function () {
|
|
return (function (t) {
|
|
function e(i) {
|
|
if (n[i]) return n[i].exports;
|
|
var r = (n[i] = { i: i, l: !1, exports: {} });
|
|
return t[i].call(r.exports, r, r.exports, e), (r.l = !0), r.exports;
|
|
}
|
|
var n = {};
|
|
return (
|
|
(e.m = t),
|
|
(e.c = n),
|
|
(e.d = function (t, n, i) {
|
|
e.o(t, n) ||
|
|
Object.defineProperty(t, n, { enumerable: !0, get: i });
|
|
}),
|
|
(e.r = function (t) {
|
|
"undefined" != typeof Symbol &&
|
|
Symbol.toStringTag &&
|
|
Object.defineProperty(t, Symbol.toStringTag, {
|
|
value: "Module",
|
|
}),
|
|
Object.defineProperty(t, "__esModule", { value: !0 });
|
|
}),
|
|
(e.t = function (t, n) {
|
|
if ((1 & n && (t = e(t)), 8 & n)) return t;
|
|
if (4 & n && "object" == typeof t && t && t.__esModule) return t;
|
|
var i = Object.create(null);
|
|
if (
|
|
(e.r(i),
|
|
Object.defineProperty(i, "default", {
|
|
enumerable: !0,
|
|
value: t,
|
|
}),
|
|
2 & n && "string" != typeof t)
|
|
)
|
|
for (var r in t)
|
|
e.d(
|
|
i,
|
|
r,
|
|
function (e) {
|
|
return t[e];
|
|
}.bind(null, r)
|
|
);
|
|
return i;
|
|
}),
|
|
(e.n = function (t) {
|
|
var n =
|
|
t && t.__esModule
|
|
? function () {
|
|
return t.default;
|
|
}
|
|
: function () {
|
|
return t;
|
|
};
|
|
return e.d(n, "a", n), n;
|
|
}),
|
|
(e.o = function (t, e) {
|
|
return Object.prototype.hasOwnProperty.call(t, e);
|
|
}),
|
|
(e.p = ""),
|
|
e((e.s = 0))
|
|
);
|
|
})([
|
|
function (t, e, n) {
|
|
function i() { }
|
|
function d(t) {
|
|
z.forEach(function (e) {
|
|
t.addEventListener(e, t === document ? x : S);
|
|
});
|
|
}
|
|
function o(t) {
|
|
return Array.isArray(t)
|
|
? t.map(o)
|
|
: "[object Object]" === b(t)
|
|
? Object.keys(t).reduce(function (e, n) {
|
|
return (e[n] = o(t[n])), e;
|
|
}, {})
|
|
: t;
|
|
}
|
|
function a(t, e) {
|
|
var n = t.calendar.querySelector(".qs-overlay"),
|
|
i = n && !n.classList.contains("qs-hidden");
|
|
(e = e || new Date(t.currentYear, t.currentMonth)),
|
|
(t.calendar.innerHTML = [s(e, t, i), u(e, t, i), l(t, i)].join(
|
|
""
|
|
)),
|
|
i &&
|
|
window.requestAnimationFrame(function () {
|
|
y(!0, t);
|
|
});
|
|
}
|
|
function s(t, e, n) {
|
|
return [
|
|
'<div class="qs-controls' + (n ? " qs-blur" : "") + '">',
|
|
'<div class="qs-arrow qs-left"></div>',
|
|
'<div class="qs-month-year">',
|
|
'<span class="qs-month">' + e.months[t.getMonth()] + "</span>",
|
|
'<span class="qs-year">' + t.getFullYear() + "</span>",
|
|
"</div>",
|
|
'<div class="qs-arrow qs-right"></div>',
|
|
"</div>",
|
|
].join("");
|
|
}
|
|
function u(t, e, n) {
|
|
var i = e.currentMonth,
|
|
r = e.currentYear,
|
|
o = e.dateSelected,
|
|
a = e.maxDate,
|
|
s = e.minDate,
|
|
u = e.showAllDates,
|
|
d = e.days,
|
|
l = e.disabledDates,
|
|
f = e.startDay,
|
|
c = e.weekendIndices,
|
|
h = e.events,
|
|
p = e.getRange ? e.getRange() : {},
|
|
m = +p.start,
|
|
g = +p.end,
|
|
y = v(new Date(t).setDate(1)),
|
|
w = y.getDay() - f,
|
|
D = w < 0 ? 7 : 0;
|
|
y.setMonth(y.getMonth() + 1), y.setDate(0);
|
|
var b = y.getDate(),
|
|
q = [],
|
|
C = D + 7 * (((w + b) / 7) | 0);
|
|
C += (w + b) % 7 ? 7 : 0;
|
|
for (var x = 1; x <= C; x++) {
|
|
var S = (x - 1) % 7,
|
|
A = d[S],
|
|
_ = x - (w >= 0 ? w : 7 + w),
|
|
T = new Date(r, i, _),
|
|
I = h[+T],
|
|
E = _ < 1 || _ > b,
|
|
k = E ? (_ < 1 ? -1 : 1) : 0,
|
|
M = E && !u,
|
|
L = M ? "" : T.getDate(),
|
|
B = +T == +o,
|
|
O = S === c[0] || S === c[1],
|
|
P = m !== g,
|
|
F = "qs-square " + A;
|
|
I && !M && (F += " qs-event"),
|
|
E && (F += " qs-outside-current-month"),
|
|
(!u && E) || (F += " qs-num"),
|
|
B && (F += " qs-active"),
|
|
(l[+T] ||
|
|
e.disabler(T) ||
|
|
(O && e.noWeekends) ||
|
|
(s && +T < +s) ||
|
|
(a && +T > +a)) &&
|
|
!M &&
|
|
(F += " qs-disabled"),
|
|
+v(new Date()) == +T && (F += " qs-current"),
|
|
+T === m && g && P && (F += " qs-range-start"),
|
|
+T > m && +T < g && (F += " qs-range-middle"),
|
|
+T === g && m && P && (F += " qs-range-end"),
|
|
M && ((F += " qs-empty"), (L = "")),
|
|
q.push(
|
|
'<div class="' +
|
|
F +
|
|
'" data-direction="' +
|
|
k +
|
|
'">' +
|
|
L +
|
|
"</div>"
|
|
);
|
|
}
|
|
var R = d
|
|
.map(function (t) {
|
|
return '<div class="qs-square qs-day">' + t + "</div>";
|
|
})
|
|
.concat(q);
|
|
return (
|
|
R.unshift(
|
|
'<div class="qs-squares' + (n ? " qs-blur" : "") + '">'
|
|
),
|
|
R.push("</div>"),
|
|
R.join("")
|
|
);
|
|
}
|
|
function l(t, e) {
|
|
var n = t.overlayPlaceholder,
|
|
i = t.overlayButton;
|
|
return [
|
|
'<div class="qs-overlay' + (e ? "" : " qs-hidden") + '">',
|
|
"<div>",
|
|
'<input class="qs-overlay-year" placeholder="' +
|
|
n +
|
|
'" inputmode="numeric" />',
|
|
'<div class="qs-close">✕</div>',
|
|
"</div>",
|
|
'<div class="qs-overlay-month-container">' +
|
|
t.overlayMonths
|
|
.map(function (t, e) {
|
|
return (
|
|
'<div class="qs-overlay-month" data-month-num="' +
|
|
e +
|
|
'">' +
|
|
t +
|
|
"</div>"
|
|
);
|
|
})
|
|
.join("") +
|
|
"</div>",
|
|
'<div class="qs-submit qs-disabled">' + i + "</div>",
|
|
"</div>",
|
|
].join("");
|
|
}
|
|
function f(t, e, n) {
|
|
var i = e.el,
|
|
r = e.calendar.querySelector(".qs-active"),
|
|
o = t.textContent,
|
|
s = e.sibling;
|
|
((i.disabled || i.readOnly) && e.respectDisabledReadOnly) ||
|
|
((e.dateSelected = n
|
|
? void 0
|
|
: new Date(e.currentYear, e.currentMonth, o)),
|
|
r && r.classList.remove("qs-active"),
|
|
n || t.classList.add("qs-active"),
|
|
h(i, e, n),
|
|
n || q(e),
|
|
s &&
|
|
(c({ instance: e, deselect: n }),
|
|
e.first &&
|
|
!s.dateSelected &&
|
|
((s.currentYear = e.currentYear),
|
|
(s.currentMonth = e.currentMonth),
|
|
(s.currentMonthName = e.currentMonthName)),
|
|
a(e),
|
|
a(s)),
|
|
e.onSelect(e, n ? void 0 : new Date(e.dateSelected)));
|
|
}
|
|
function c(t) {
|
|
var e = t.instance.first ? t.instance : t.instance.sibling,
|
|
n = e.sibling;
|
|
e === t.instance
|
|
? t.deselect
|
|
? ((e.minDate = e.originalMinDate),
|
|
(n.minDate = n.originalMinDate))
|
|
: (n.minDate = e.dateSelected)
|
|
: t.deselect
|
|
? ((n.maxDate = n.originalMaxDate),
|
|
(e.maxDate = e.originalMaxDate))
|
|
: (e.maxDate = n.dateSelected);
|
|
}
|
|
function h(t, e, n) {
|
|
if (!e.nonInput)
|
|
return n
|
|
? (t.value = "")
|
|
: e.formatter !== i
|
|
? e.formatter(t, e.dateSelected, e)
|
|
: void (t.value = e.dateSelected.toDateString());
|
|
}
|
|
function p(t, e, n, i) {
|
|
n || i
|
|
? (n && (e.currentYear = +n), i && (e.currentMonth = +i))
|
|
: ((e.currentMonth += t.contains("qs-right") ? 1 : -1),
|
|
12 === e.currentMonth
|
|
? ((e.currentMonth = 0), e.currentYear++)
|
|
: -1 === e.currentMonth &&
|
|
((e.currentMonth = 11), e.currentYear--)),
|
|
(e.currentMonthName = e.months[e.currentMonth]),
|
|
a(e),
|
|
e.onMonthChange(e);
|
|
}
|
|
function D(t) {
|
|
if (!t.noPosition) {
|
|
var e = t.position.top,
|
|
n = t.position.right;
|
|
if (t.position.centered)
|
|
return t.calendarContainer.classList.add("qs-centered");
|
|
var i = t.positionedEl.getBoundingClientRect(),
|
|
r = t.el.getBoundingClientRect(),
|
|
o = t.calendarContainer.getBoundingClientRect(),
|
|
a = r.top - i.top + (e ? -1 * o.height : r.height) + "px",
|
|
s = r.left - i.left + (n ? r.width - o.width : 0) + "px";
|
|
t.calendarContainer.style.setProperty("top", a),
|
|
t.calendarContainer.style.setProperty("left", s);
|
|
}
|
|
}
|
|
function m(t) {
|
|
return (
|
|
"[object Date]" === b(t) && "Invalid Date" !== t.toString()
|
|
);
|
|
}
|
|
function v(t) {
|
|
if (m(t) || ("number" == typeof t && !isNaN(t))) {
|
|
var e = new Date(+t);
|
|
return new Date(e.getFullYear(), e.getMonth(), e.getDate());
|
|
}
|
|
}
|
|
function q(t) {
|
|
t.disabled ||
|
|
(!t.calendarContainer.classList.contains("qs-hidden") &&
|
|
!t.alwaysShow &&
|
|
("overlay" !== t.defaultView && y(!0, t),
|
|
t.calendarContainer.classList.add("qs-hidden"),
|
|
t.onHide(t)));
|
|
}
|
|
function g(t) {
|
|
t.disabled ||
|
|
(t.calendarContainer.classList.remove("qs-hidden"),
|
|
"overlay" === t.defaultView && y(!1, t),
|
|
D(t),
|
|
t.onShow(t));
|
|
}
|
|
function y(t, e) {
|
|
var n = e.calendar,
|
|
i = n.querySelector(".qs-overlay"),
|
|
r = i.querySelector(".qs-overlay-year"),
|
|
o = n.querySelector(".qs-controls"),
|
|
a = n.querySelector(".qs-squares");
|
|
t
|
|
? (i.classList.add("qs-hidden"),
|
|
o.classList.remove("qs-blur"),
|
|
a.classList.remove("qs-blur"),
|
|
(r.value = ""))
|
|
: (i.classList.remove("qs-hidden"),
|
|
o.classList.add("qs-blur"),
|
|
a.classList.add("qs-blur"),
|
|
r.focus());
|
|
}
|
|
function w(t, e, n, i) {
|
|
var r = isNaN(+new Date().setFullYear(e.value || void 0)),
|
|
o = r ? null : e.value;
|
|
if (13 === t.which || 13 === t.keyCode || "click" === t.type)
|
|
i
|
|
? p(null, n, o, i)
|
|
: r || e.classList.contains("qs-disabled") || p(null, n, o);
|
|
else if (n.calendar.contains(e))
|
|
n.calendar
|
|
.querySelector(".qs-submit")
|
|
.classList[r ? "add" : "remove"]("qs-disabled");
|
|
}
|
|
function b(t) {
|
|
return {}.toString.call(t);
|
|
}
|
|
function C(t) {
|
|
P.forEach(function (e) {
|
|
e !== t && q(e);
|
|
});
|
|
}
|
|
function x(t) {
|
|
if (!t.__qs_shadow_dom) {
|
|
var e = t.which || t.keyCode,
|
|
n = t.type,
|
|
r = t.target,
|
|
i = r.classList,
|
|
o = P.filter(function (t) {
|
|
return t.calendar.contains(r) || t.el === r;
|
|
})[0],
|
|
s = o && o.calendar.contains(r);
|
|
if (!(o && o.isMobile && o.disableMobile))
|
|
if ("click" === n) {
|
|
if (!o) return P.forEach(q);
|
|
if (o.disabled) return;
|
|
var d = o.calendar,
|
|
u = o.calendarContainer,
|
|
l = o.disableYearOverlay,
|
|
c = o.nonInput,
|
|
h = d.querySelector(".qs-overlay-year"),
|
|
m = !!d.querySelector(".qs-hidden"),
|
|
v = d.querySelector(".qs-month-year").contains(r),
|
|
D = r.dataset.monthNum;
|
|
if (o.noPosition && !s)
|
|
(u.classList.contains("qs-hidden") ? g : q)(o);
|
|
else if (i.contains("qs-arrow")) p(i, o);
|
|
else if (v || i.contains("qs-close")) l || y(!m, o);
|
|
else if (D) w(t, h, o, D);
|
|
else {
|
|
if (i.contains("qs-disabled")) return;
|
|
if (i.contains("qs-num")) {
|
|
var b = r.textContent,
|
|
x = +r.dataset.direction,
|
|
S = new Date(o.currentYear, o.currentMonth + x, b);
|
|
if (x) {
|
|
(o.currentYear = S.getFullYear()),
|
|
(o.currentMonth = S.getMonth()),
|
|
(o.currentMonthName = F[o.currentMonth]),
|
|
a(o);
|
|
for (
|
|
var A,
|
|
_ = o.calendar.querySelectorAll(
|
|
'[data-direction="0"]'
|
|
),
|
|
T = 0;
|
|
!A;
|
|
|
|
) {
|
|
var I = _[T];
|
|
I.textContent === b && (A = I), T++;
|
|
}
|
|
r = A;
|
|
}
|
|
return void (+S == +o.dateSelected
|
|
? f(r, o, !0)
|
|
: r.classList.contains("qs-disabled") || f(r, o));
|
|
}
|
|
i.contains("qs-submit")
|
|
? w(t, h, o)
|
|
: c && r === o.el && (g(o), C(o));
|
|
}
|
|
} else if ("focusin" === n && o) g(o), C(o);
|
|
else if ("keydown" === n && 9 === e && o) q(o);
|
|
else if ("keydown" === n && o && !o.disabled) {
|
|
var E = !o.calendar
|
|
.querySelector(".qs-overlay")
|
|
.classList.contains("qs-hidden");
|
|
13 === e && E && s
|
|
? w(t, r, o)
|
|
: 27 === e && E && s && y(!0, o);
|
|
} else if ("input" === n) {
|
|
if (!o || !o.calendar.contains(r)) return;
|
|
var k = o.calendar.querySelector(".qs-submit"),
|
|
M = r.value
|
|
.split("")
|
|
.reduce(function (t, e) {
|
|
return t || "0" !== e
|
|
? t + (e.match(/[0-9]/) ? e : "")
|
|
: "";
|
|
}, "")
|
|
.slice(0, 4);
|
|
(r.value = M),
|
|
k.classList[4 === M.length ? "remove" : "add"](
|
|
"qs-disabled"
|
|
);
|
|
}
|
|
}
|
|
}
|
|
function S(t) {
|
|
x(t), (t.__qs_shadow_dom = !0);
|
|
}
|
|
function A(t, e) {
|
|
z.forEach(function (n) {
|
|
t.removeEventListener(n, e);
|
|
});
|
|
}
|
|
function _() {
|
|
g(this);
|
|
}
|
|
function T() {
|
|
q(this);
|
|
}
|
|
function I(t, e) {
|
|
var n = v(t),
|
|
i = this.currentYear,
|
|
r = this.currentMonth,
|
|
o = this.sibling;
|
|
if (null == t)
|
|
return (
|
|
(this.dateSelected = void 0),
|
|
h(this.el, this, !0),
|
|
o && (c({ instance: this, deselect: !0 }), a(o)),
|
|
a(this),
|
|
this
|
|
);
|
|
if (!m(t))
|
|
throw new Error("`setDate` needs a JavaScript Date object.");
|
|
if (
|
|
this.disabledDates[+n] ||
|
|
n < this.minDate ||
|
|
n > this.maxDate
|
|
)
|
|
throw new Error(
|
|
"You can't manually set a date that's disabled."
|
|
);
|
|
(this.dateSelected = n),
|
|
e &&
|
|
((this.currentYear = n.getFullYear()),
|
|
(this.currentMonth = n.getMonth()),
|
|
(this.currentMonthName = this.months[n.getMonth()])),
|
|
h(this.el, this),
|
|
o && (c({ instance: this }), a(o));
|
|
var s = i === n.getFullYear() && r === n.getMonth();
|
|
return (
|
|
s || e ? a(this, n) : s || a(this, new Date(i, r, 1)), this
|
|
);
|
|
}
|
|
function E(t) {
|
|
return M(this, t, !0);
|
|
}
|
|
function k(t) {
|
|
return M(this, t);
|
|
}
|
|
function M(t, e, n) {
|
|
function i() {
|
|
return "original" + d + "Date";
|
|
}
|
|
function o() {
|
|
return d.toLowerCase() + "Date";
|
|
}
|
|
function s() {
|
|
return "set" + d;
|
|
}
|
|
function u() {
|
|
throw new Error("Out-of-range date passed to " + s());
|
|
}
|
|
var l = t.dateSelected,
|
|
r = t.first,
|
|
f = t.sibling,
|
|
c = t.minDate,
|
|
h = t.maxDate,
|
|
p = v(e),
|
|
d = n ? "Min" : "Max";
|
|
if (null == e)
|
|
(t[i()] = void 0),
|
|
f
|
|
? ((f[i()] = void 0),
|
|
n
|
|
? ((r && !l) || (!r && !f.dateSelected)) &&
|
|
((t.minDate = void 0), (f.minDate = void 0))
|
|
: ((r && !f.dateSelected) || (!r && !l)) &&
|
|
((t.maxDate = void 0), (f.maxDate = void 0)))
|
|
: (t[o()] = void 0);
|
|
else {
|
|
if (!m(e)) throw new Error("Invalid date passed to " + s());
|
|
f
|
|
? (((r && n && p > (l || h)) ||
|
|
(r && !n && p < (f.dateSelected || c)) ||
|
|
(!r && n && p > (f.dateSelected || h)) ||
|
|
(!r && !n && p < (l || c))) &&
|
|
u(),
|
|
(t[i()] = p),
|
|
(f[i()] = p),
|
|
((n && ((r && !l) || (!r && !f.dateSelected))) ||
|
|
(!n && ((r && !f.dateSelected) || (!r && !l)))) &&
|
|
((t[o()] = p), (f[o()] = p)))
|
|
: (((n && p > (l || h)) || (!n && p < (l || c))) && u(),
|
|
(t[o()] = p));
|
|
}
|
|
return f && a(f), a(t), t;
|
|
}
|
|
function L() {
|
|
var t = this.first ? this : this.sibling,
|
|
e = t.sibling;
|
|
return { start: t.dateSelected, end: e.dateSelected };
|
|
}
|
|
function R() {
|
|
var t = this.shadowDom,
|
|
e = this.positionedEl,
|
|
n = this.calendarContainer,
|
|
r = this.sibling,
|
|
i = this;
|
|
this.inlinePosition &&
|
|
(P.some(function (t) {
|
|
return t !== i && t.positionedEl === e;
|
|
}) ||
|
|
e.style.setProperty("position", null)),
|
|
n.remove(),
|
|
(P = P.filter(function (t) {
|
|
return t !== i;
|
|
})),
|
|
r && delete r.sibling,
|
|
P.length || A(document, x);
|
|
var o = P.some(function (e) {
|
|
return e.shadowDom === t;
|
|
});
|
|
for (var a in (t && !o && A(t, S), this)) delete this[a];
|
|
P.length ||
|
|
z.forEach(function (t) {
|
|
document.removeEventListener(t, x);
|
|
});
|
|
}
|
|
function B(t, e) {
|
|
var n = new Date(t);
|
|
if (!m(n)) throw new Error("Invalid date passed to `navigate`");
|
|
(this.currentYear = n.getFullYear()),
|
|
(this.currentMonth = n.getMonth()),
|
|
a(this),
|
|
e && this.onMonthChange(this);
|
|
}
|
|
function O() {
|
|
var t = !this.calendarContainer.classList.contains("qs-hidden"),
|
|
e = !this.calendarContainer
|
|
.querySelector(".qs-overlay")
|
|
.classList.contains("qs-hidden");
|
|
t && y(e, this);
|
|
}
|
|
n.r(e);
|
|
var P = [],
|
|
r = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
|
|
F = [
|
|
"January",
|
|
"February",
|
|
"March",
|
|
"April",
|
|
"May",
|
|
"June",
|
|
"July",
|
|
"August",
|
|
"September",
|
|
"October",
|
|
"November",
|
|
"December",
|
|
],
|
|
N = {
|
|
t: "top",
|
|
r: "right",
|
|
b: "bottom",
|
|
l: "left",
|
|
c: "centered",
|
|
},
|
|
z = ["click", "focusin", "keydown", "input"];
|
|
e.default = function (t, e) {
|
|
var n = (function (t, e) {
|
|
var n,
|
|
a,
|
|
d = (function (t) {
|
|
function e(t) {
|
|
throw new Error(
|
|
'"dateSelected" in options is ' +
|
|
(t ? "less" : "greater") +
|
|
' than "' +
|
|
(t || "max") +
|
|
'Date".'
|
|
);
|
|
}
|
|
var n = o(t);
|
|
n.events &&
|
|
(n.events = n.events.reduce(function (t, e) {
|
|
if (!m(e))
|
|
throw new Error(
|
|
'"options.events" must only contain valid JavaScript Date objects.'
|
|
);
|
|
return (t[+v(e)] = !0), t;
|
|
}, {})),
|
|
[
|
|
"startDate",
|
|
"dateSelected",
|
|
"minDate",
|
|
"maxDate",
|
|
].forEach(function (t) {
|
|
var e = n[t];
|
|
if (e && !m(e))
|
|
throw new Error(
|
|
'"options.' +
|
|
t +
|
|
'" needs to be a valid JavaScript Date object.'
|
|
);
|
|
n[t] = v(e);
|
|
});
|
|
var a = n.position,
|
|
s = n.maxDate,
|
|
u = n.minDate,
|
|
d = n.dateSelected,
|
|
l = n.overlayPlaceholder,
|
|
f = n.overlayButton,
|
|
c = n.startDay,
|
|
h = n.id;
|
|
if (
|
|
((n.startDate = v(n.startDate || d || new Date())),
|
|
(n.disabledDates = (n.disabledDates || []).reduce(
|
|
function (t, e) {
|
|
var n = +v(e);
|
|
if (!m(e))
|
|
throw new Error(
|
|
'You supplied an invalid date to "options.disabledDates".'
|
|
);
|
|
if (n === +v(d))
|
|
throw new Error(
|
|
'"disabledDates" cannot contain the same date as "dateSelected".'
|
|
);
|
|
return (t[n] = 1), t;
|
|
},
|
|
{}
|
|
)),
|
|
n.hasOwnProperty("id") && null == h)
|
|
)
|
|
throw new Error("`id` cannot be `null` or `undefined`");
|
|
if (null != h) {
|
|
var p = P.filter(function (t) {
|
|
return t.id === h;
|
|
});
|
|
if (p.length > 1)
|
|
throw new Error(
|
|
"Only two datepickers can share an id."
|
|
);
|
|
p.length
|
|
? ((n.second = !0), (n.sibling = p[0]))
|
|
: (n.first = !0);
|
|
}
|
|
var g = ["tr", "tl", "br", "bl", "c"].some(function (t) {
|
|
return a === t;
|
|
});
|
|
if (a && !g)
|
|
throw new Error(
|
|
'"options.position" must be one of the following: tl, tr, bl, br, or c.'
|
|
);
|
|
if (
|
|
((n.position = (function (t) {
|
|
var e = t[0],
|
|
n = t[1],
|
|
i = {};
|
|
return (i[N[e]] = 1), n && (i[N[n]] = 1), i;
|
|
})(a || "bl")),
|
|
s < u)
|
|
)
|
|
throw new Error(
|
|
'"maxDate" in options is less than "minDate".'
|
|
);
|
|
if (
|
|
(d && (u > d && e("min"), s < d && e()),
|
|
[
|
|
"onSelect",
|
|
"onShow",
|
|
"onHide",
|
|
"onMonthChange",
|
|
"formatter",
|
|
"disabler",
|
|
].forEach(function (t) {
|
|
"function" != typeof n[t] && (n[t] = i);
|
|
}),
|
|
[
|
|
"customDays",
|
|
"customMonths",
|
|
"customOverlayMonths",
|
|
].forEach(function (t, e) {
|
|
var i = n[t],
|
|
r = e ? 12 : 7;
|
|
if (i) {
|
|
if (
|
|
!Array.isArray(i) ||
|
|
i.length !== r ||
|
|
i.some(function (t) {
|
|
return "string" != typeof t;
|
|
})
|
|
)
|
|
throw new Error(
|
|
'"' +
|
|
t +
|
|
'" must be an array with ' +
|
|
r +
|
|
" strings."
|
|
);
|
|
n[e ? (e < 2 ? "months" : "overlayMonths") : "days"] =
|
|
i;
|
|
}
|
|
}),
|
|
c && c > 0 && c < 7)
|
|
) {
|
|
var y = (n.customDays || r).slice(),
|
|
D = y.splice(0, c);
|
|
(n.customDays = y.concat(D)),
|
|
(n.startDay = +c),
|
|
(n.weekendIndices = [y.length - 1, y.length]);
|
|
} else (n.startDay = 0), (n.weekendIndices = [6, 0]);
|
|
"string" != typeof l && delete n.overlayPlaceholder,
|
|
"string" != typeof f && delete n.overlayButton;
|
|
var q = n.defaultView;
|
|
if (q && "calendar" !== q && "overlay" !== q)
|
|
throw new Error(
|
|
'options.defaultView must either be "calendar" or "overlay".'
|
|
);
|
|
return (n.defaultView = q || "calendar"), n;
|
|
})(
|
|
e || {
|
|
startDate: v(new Date()),
|
|
position: "bl",
|
|
defaultView: "calendar",
|
|
}
|
|
),
|
|
s = t;
|
|
if ("string" == typeof s)
|
|
s =
|
|
"#" === s[0]
|
|
? document.getElementById(s.slice(1))
|
|
: document.querySelector(s);
|
|
else {
|
|
if ("[object ShadowRoot]" === b(s))
|
|
throw new Error(
|
|
"Using a shadow DOM as your selector is not supported."
|
|
);
|
|
for (var u, l = s.parentNode; !u;) {
|
|
var f = b(l);
|
|
"[object HTMLDocument]" === f
|
|
? (u = !0)
|
|
: "[object ShadowRoot]" === f
|
|
? ((u = !0), (n = l), (a = l.host))
|
|
: (l = l.parentNode);
|
|
}
|
|
}
|
|
if (!s) throw new Error("No selector / element found.");
|
|
if (
|
|
P.some(function (t) {
|
|
return t.el === s;
|
|
})
|
|
)
|
|
throw new Error(
|
|
"A datepicker already exists on that element."
|
|
);
|
|
var c = s === document.body,
|
|
p = n
|
|
? s.parentElement || n
|
|
: c
|
|
? document.body
|
|
: s.parentElement,
|
|
y = n ? s.parentElement || a : p,
|
|
D = document.createElement("div"),
|
|
q = document.createElement("div");
|
|
(D.className = "qs-datepicker-container qs-hidden"),
|
|
(q.className = "qs-datepicker");
|
|
var w = {
|
|
shadowDom: n,
|
|
customElement: a,
|
|
positionedEl: y,
|
|
el: s,
|
|
parent: p,
|
|
nonInput: "INPUT" !== s.nodeName,
|
|
noPosition: c,
|
|
position: !c && d.position,
|
|
startDate: d.startDate,
|
|
dateSelected: d.dateSelected,
|
|
disabledDates: d.disabledDates,
|
|
minDate: d.minDate,
|
|
maxDate: d.maxDate,
|
|
noWeekends: !!d.noWeekends,
|
|
weekendIndices: d.weekendIndices,
|
|
calendarContainer: D,
|
|
calendar: q,
|
|
currentMonth: (d.startDate || d.dateSelected).getMonth(),
|
|
currentMonthName: (d.months || F)[
|
|
(d.startDate || d.dateSelected).getMonth()
|
|
],
|
|
currentYear: (d.startDate || d.dateSelected).getFullYear(),
|
|
events: d.events || {},
|
|
defaultView: d.defaultView,
|
|
setDate: I,
|
|
remove: R,
|
|
setMin: E,
|
|
setMax: k,
|
|
show: _,
|
|
hide: T,
|
|
navigate: B,
|
|
toggleOverlay: O,
|
|
onSelect: d.onSelect,
|
|
onShow: d.onShow,
|
|
onHide: d.onHide,
|
|
onMonthChange: d.onMonthChange,
|
|
formatter: d.formatter,
|
|
disabler: d.disabler,
|
|
months: d.months || F,
|
|
days: d.customDays || r,
|
|
startDay: d.startDay,
|
|
overlayMonths:
|
|
d.overlayMonths ||
|
|
(d.months || F).map(function (t) {
|
|
return t.slice(0, 3);
|
|
}),
|
|
overlayPlaceholder: d.overlayPlaceholder || "4-digit year",
|
|
overlayButton: d.overlayButton || "Submit",
|
|
disableYearOverlay: !!d.disableYearOverlay,
|
|
disableMobile: !!d.disableMobile,
|
|
isMobile: "ontouchstart" in window,
|
|
alwaysShow: !!d.alwaysShow,
|
|
id: d.id,
|
|
showAllDates: !!d.showAllDates,
|
|
respectDisabledReadOnly: !!d.respectDisabledReadOnly,
|
|
first: d.first,
|
|
second: d.second,
|
|
};
|
|
if (d.sibling) {
|
|
var C = d.sibling,
|
|
x = w,
|
|
S = C.minDate || x.minDate,
|
|
A = C.maxDate || x.maxDate;
|
|
(x.sibling = C),
|
|
(C.sibling = x),
|
|
(C.minDate = S),
|
|
(C.maxDate = A),
|
|
(x.minDate = S),
|
|
(x.maxDate = A),
|
|
(C.originalMinDate = S),
|
|
(C.originalMaxDate = A),
|
|
(x.originalMinDate = S),
|
|
(x.originalMaxDate = A),
|
|
(C.getRange = L),
|
|
(x.getRange = L);
|
|
}
|
|
d.dateSelected && h(s, w);
|
|
var M = getComputedStyle(y).position;
|
|
c ||
|
|
(M && "static" !== M) ||
|
|
((w.inlinePosition = !0),
|
|
y.style.setProperty("position", "relative"));
|
|
var z = P.filter(function (t) {
|
|
return t.positionedEl === w.positionedEl;
|
|
});
|
|
return (
|
|
z.some(function (t) {
|
|
return t.inlinePosition;
|
|
}) &&
|
|
((w.inlinePosition = !0),
|
|
z.forEach(function (t) {
|
|
t.inlinePosition = !0;
|
|
})),
|
|
D.appendChild(q),
|
|
p.appendChild(D),
|
|
w.alwaysShow && g(w),
|
|
w
|
|
);
|
|
})(t, e);
|
|
if (
|
|
(P.length || d(document),
|
|
n.shadowDom &&
|
|
(P.some(function (t) {
|
|
return t.shadowDom === n.shadowDom;
|
|
}) ||
|
|
d(n.shadowDom)),
|
|
P.push(n),
|
|
n.second)
|
|
) {
|
|
var s = n.sibling;
|
|
c({ instance: n, deselect: !n.dateSelected }),
|
|
c({ instance: s, deselect: !s.dateSelected }),
|
|
a(s);
|
|
}
|
|
return (
|
|
a(n, n.startDate || n.dateSelected), n.alwaysShow && D(n), n
|
|
);
|
|
};
|
|
},
|
|
]).default;
|
|
}),
|
|
!void (true
|
|
? (t.exports = o())
|
|
: "function" == typeof define && define.amd
|
|
? define([], o)
|
|
: "object" == typeof e
|
|
? (e.datepicker = o())
|
|
: (i.datepicker = o()));
|
|
},
|
|
9854: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
if ("function" == typeof Symbol && "symbol" == typeof Symbol.iterator)
|
|
i = function t(e) {
|
|
return typeof e;
|
|
};
|
|
else
|
|
i = function t(e) {
|
|
return e &&
|
|
"function" == typeof Symbol &&
|
|
e.constructor === Symbol &&
|
|
e !== Symbol.prototype
|
|
? "symbol"
|
|
: typeof e;
|
|
};
|
|
return i(t);
|
|
}
|
|
var o;
|
|
"use strict",
|
|
(function (a) {
|
|
var s = arguments,
|
|
u =
|
|
((l =
|
|
/d{1,4}|D{3,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|W{1,2}|[LlopSZN]|"[^"]*"|'[^']*'/g),
|
|
(f =
|
|
/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g),
|
|
(c = /[^-+\dA-Z]/g),
|
|
function (t, e, n, i) {
|
|
if (1 === s.length && "string" === g(t) && !/\d/.test(t))
|
|
(e = t), (t = void 0);
|
|
if (!((t = t || 0 === t ? t : new Date()) instanceof Date))
|
|
t = new Date(t);
|
|
if (isNaN(t)) throw TypeError("Invalid date");
|
|
var o = (e = String(u.masks[e] || e || u.masks["default"])).slice(
|
|
0,
|
|
4
|
|
);
|
|
if ("UTC:" === o || "GMT:" === o)
|
|
if (((e = e.slice(4)), (n = true), "GMT:" === o)) i = true;
|
|
var a = function t() {
|
|
return n ? "getUTC" : "get";
|
|
},
|
|
y = function d() {
|
|
return t[a() + "Date"]();
|
|
},
|
|
D = function D() {
|
|
return t[a() + "Day"]();
|
|
},
|
|
w = function e() {
|
|
return t[a() + "Month"]();
|
|
},
|
|
b = function e() {
|
|
return t[a() + "FullYear"]();
|
|
},
|
|
C = function e() {
|
|
return t[a() + "Hours"]();
|
|
},
|
|
x = function e() {
|
|
return t[a() + "Minutes"]();
|
|
},
|
|
S = function e() {
|
|
return t[a() + "Seconds"]();
|
|
},
|
|
A = function e() {
|
|
return t[a() + "Milliseconds"]();
|
|
},
|
|
_ = function e() {
|
|
return n ? 0 : t.getTimezoneOffset();
|
|
},
|
|
T = function e() {
|
|
return m(t);
|
|
},
|
|
I = function e() {
|
|
return v(t);
|
|
},
|
|
E = {
|
|
d: function d() {
|
|
return y();
|
|
},
|
|
dd: function t() {
|
|
return h(y());
|
|
},
|
|
ddd: function t() {
|
|
return u.i18n.dayNames[D()];
|
|
},
|
|
DDD: function t() {
|
|
return p({
|
|
y: b(),
|
|
m: w(),
|
|
d: y(),
|
|
_: a(),
|
|
dayName: u.i18n.dayNames[D()],
|
|
short: true,
|
|
});
|
|
},
|
|
dddd: function t() {
|
|
return u.i18n.dayNames[D() + 7];
|
|
},
|
|
DDDD: function t() {
|
|
return p({
|
|
y: b(),
|
|
m: w(),
|
|
d: y(),
|
|
_: a(),
|
|
dayName: u.i18n.dayNames[D() + 7],
|
|
});
|
|
},
|
|
m: function t() {
|
|
return w() + 1;
|
|
},
|
|
mm: function t() {
|
|
return h(w() + 1);
|
|
},
|
|
mmm: function t() {
|
|
return u.i18n.monthNames[w()];
|
|
},
|
|
mmmm: function t() {
|
|
return u.i18n.monthNames[w() + 12];
|
|
},
|
|
yy: function t() {
|
|
return String(b()).slice(2);
|
|
},
|
|
yyyy: function t() {
|
|
return h(b(), 4);
|
|
},
|
|
h: function t() {
|
|
return C() % 12 || 12;
|
|
},
|
|
hh: function t() {
|
|
return h(C() % 12 || 12);
|
|
},
|
|
H: function t() {
|
|
return C();
|
|
},
|
|
HH: function t() {
|
|
return h(C());
|
|
},
|
|
M: function t() {
|
|
return x();
|
|
},
|
|
MM: function t() {
|
|
return h(x());
|
|
},
|
|
s: function t() {
|
|
return S();
|
|
},
|
|
ss: function t() {
|
|
return h(S());
|
|
},
|
|
l: function t() {
|
|
return h(A(), 3);
|
|
},
|
|
L: function t() {
|
|
return h(Math.floor(A() / 10));
|
|
},
|
|
t: function t() {
|
|
return C() < 12 ? u.i18n.timeNames[0] : u.i18n.timeNames[1];
|
|
},
|
|
tt: function t() {
|
|
return C() < 12 ? u.i18n.timeNames[2] : u.i18n.timeNames[3];
|
|
},
|
|
T: function t() {
|
|
return C() < 12 ? u.i18n.timeNames[4] : u.i18n.timeNames[5];
|
|
},
|
|
TT: function t() {
|
|
return C() < 12 ? u.i18n.timeNames[6] : u.i18n.timeNames[7];
|
|
},
|
|
Z: function e() {
|
|
return i
|
|
? "GMT"
|
|
: n
|
|
? "UTC"
|
|
: (String(t).match(f) || [""])
|
|
.pop()
|
|
.replace(c, "")
|
|
.replace(/GMT\+0000/g, "UTC");
|
|
},
|
|
o: function t() {
|
|
return (
|
|
(_() > 0 ? "-" : "+") +
|
|
h(
|
|
100 * Math.floor(Math.abs(_()) / 60) +
|
|
(Math.abs(_()) % 60),
|
|
4
|
|
)
|
|
);
|
|
},
|
|
p: function t() {
|
|
return (
|
|
(_() > 0 ? "-" : "+") +
|
|
h(Math.floor(Math.abs(_()) / 60), 2) +
|
|
":" +
|
|
h(Math.floor(Math.abs(_()) % 60), 2)
|
|
);
|
|
},
|
|
S: function t() {
|
|
return ["th", "st", "nd", "rd"][
|
|
y() % 10 > 3
|
|
? 0
|
|
: (((y() % 100) - (y() % 10) != 10) * y()) % 10
|
|
];
|
|
},
|
|
W: function t() {
|
|
return T();
|
|
},
|
|
WW: function t() {
|
|
return h(T());
|
|
},
|
|
N: function t() {
|
|
return I();
|
|
},
|
|
};
|
|
return e.replace(l, function (t) {
|
|
if (t in E) return E[t]();
|
|
else return t.slice(1, t.length - 1);
|
|
});
|
|
}),
|
|
l,
|
|
f,
|
|
c;
|
|
(u.masks = {
|
|
default: "ddd mmm dd yyyy HH:MM:ss",
|
|
shortDate: "m/d/yy",
|
|
paddedShortDate: "mm/dd/yyyy",
|
|
mediumDate: "mmm d, yyyy",
|
|
longDate: "mmmm d, yyyy",
|
|
fullDate: "dddd, mmmm d, yyyy",
|
|
shortTime: "h:MM TT",
|
|
mediumTime: "h:MM:ss TT",
|
|
longTime: "h:MM:ss TT Z",
|
|
isoDate: "yyyy-mm-dd",
|
|
isoTime: "HH:MM:ss",
|
|
isoDateTime: "yyyy-mm-dd'T'HH:MM:sso",
|
|
isoUtcDateTime: "UTC:yyyy-mm-dd'T'HH:MM:ss'Z'",
|
|
expiresHeaderFormat: "ddd, dd mmm yyyy HH:MM:ss Z",
|
|
}),
|
|
(u.i18n = {
|
|
dayNames: [
|
|
"Sun",
|
|
"Mon",
|
|
"Tue",
|
|
"Wed",
|
|
"Thu",
|
|
"Fri",
|
|
"Sat",
|
|
"Sunday",
|
|
"Monday",
|
|
"Tuesday",
|
|
"Wednesday",
|
|
"Thursday",
|
|
"Friday",
|
|
"Saturday",
|
|
],
|
|
monthNames: [
|
|
"Jan",
|
|
"Feb",
|
|
"Mar",
|
|
"Apr",
|
|
"May",
|
|
"Jun",
|
|
"Jul",
|
|
"Aug",
|
|
"Sep",
|
|
"Oct",
|
|
"Nov",
|
|
"Dec",
|
|
"January",
|
|
"February",
|
|
"March",
|
|
"April",
|
|
"May",
|
|
"June",
|
|
"July",
|
|
"August",
|
|
"September",
|
|
"October",
|
|
"November",
|
|
"December",
|
|
],
|
|
timeNames: ["a", "p", "am", "pm", "A", "P", "AM", "PM"],
|
|
});
|
|
var h = function t(e, n) {
|
|
for (e = String(e), n = n || 2; e.length < n;) e = "0" + e;
|
|
return e;
|
|
},
|
|
p = function t(e) {
|
|
var n = e.y,
|
|
i = e.m,
|
|
d = e.d,
|
|
o = e._,
|
|
a = e.dayName,
|
|
s = e["short"],
|
|
u = void 0 === s ? false : s,
|
|
l = new Date(),
|
|
f = new Date();
|
|
f.setDate(f[o + "Date"]() - 1);
|
|
var c = new Date();
|
|
c.setDate(c[o + "Date"]() + 1);
|
|
var h = function t() {
|
|
return l[o + "Date"]();
|
|
},
|
|
p = function t() {
|
|
return l[o + "Month"]();
|
|
},
|
|
m,
|
|
v = function t() {
|
|
return f[o + "Date"]();
|
|
},
|
|
g = function t() {
|
|
return f[o + "Month"]();
|
|
},
|
|
y = function t() {
|
|
return f[o + "FullYear"]();
|
|
},
|
|
w = function t() {
|
|
return c[o + "Date"]();
|
|
},
|
|
b = function t() {
|
|
return c[o + "Month"]();
|
|
},
|
|
C = function t() {
|
|
return c[o + "FullYear"]();
|
|
};
|
|
if (
|
|
(function t() {
|
|
return l[o + "FullYear"]();
|
|
})() === n &&
|
|
p() === i &&
|
|
h() === d
|
|
)
|
|
return u ? "Tdy" : "Today";
|
|
else if (y() === n && g() === i && v() === d)
|
|
return u ? "Ysd" : "Yesterday";
|
|
else if (C() === n && b() === i && w() === d)
|
|
return u ? "Tmw" : "Tomorrow";
|
|
return a;
|
|
},
|
|
m = function t(e) {
|
|
var n = new Date(e.getFullYear(), e.getMonth(), e.getDate());
|
|
n.setDate(n.getDate() - ((n.getDay() + 6) % 7) + 3);
|
|
var i = new Date(n.getFullYear(), 0, 4);
|
|
i.setDate(i.getDate() - ((i.getDay() + 6) % 7) + 3);
|
|
var o = n.getTimezoneOffset() - i.getTimezoneOffset();
|
|
n.setHours(n.getHours() - o);
|
|
var a = (n - i) / (864e5 * 7);
|
|
return 1 + Math.floor(a);
|
|
},
|
|
v = function t(e) {
|
|
var n = e.getDay();
|
|
if (0 === n) n = 7;
|
|
return n;
|
|
},
|
|
g = function t(e) {
|
|
if (null === e) return "null";
|
|
if (void 0 === e) return "undefined";
|
|
if ("object" !== i(e)) return i(e);
|
|
if (Array.isArray(e)) return "array";
|
|
else return {}.toString.call(e).slice(8, -1).toLowerCase();
|
|
};
|
|
if (true)
|
|
!(
|
|
void 0 !==
|
|
(o = function () {
|
|
return u;
|
|
}.call(e, n, e, t)) && (t.exports = o)
|
|
);
|
|
else if ("object" === (void 0 === e ? "undefined" : i(e)))
|
|
t.exports = u;
|
|
else a.dateFormat = u;
|
|
})(void 0);
|
|
},
|
|
9855: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(function () {
|
|
var selector;
|
|
i("form input[type=time]").each(function () {
|
|
var t = i(this),
|
|
e = t.attr("data-time-value") || "";
|
|
if ("--:--" !== e) {
|
|
if (!e) {
|
|
var n = new Date();
|
|
e =
|
|
("0" + n.getHours()).slice(-2) +
|
|
":" +
|
|
("0" + n.getMinutes()).slice(-2);
|
|
}
|
|
t.val(e);
|
|
}
|
|
});
|
|
});
|
|
},
|
|
9856: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
return new Promise(function (e) {
|
|
var n = document.createElement("script");
|
|
(n.async = ""),
|
|
(n.onload = e),
|
|
(n.src = t),
|
|
document.head.appendChild(n);
|
|
});
|
|
}
|
|
function o(t) {
|
|
return new Promise(function (e) {
|
|
var link = document.createElement("link");
|
|
(link.rel = "stylesheet"),
|
|
(link.type = "text/css"),
|
|
(link.onload = e),
|
|
(link.href = t),
|
|
document.head.appendChild(link);
|
|
});
|
|
}
|
|
function a(t, e) {
|
|
var n = [
|
|
"Invalid number",
|
|
"Invalid country code",
|
|
"Too short",
|
|
"Too long",
|
|
"Invalid number",
|
|
];
|
|
e.each(function () {
|
|
var container = s(this),
|
|
e = container.find("input[type=tel]");
|
|
container.replaceWith(e),
|
|
e.each(function () {
|
|
var input = s(this)[0];
|
|
input.removeAttribute("pattern");
|
|
var e = intlTelInput(input, {
|
|
autoPlaceholder: "aggressive",
|
|
utilsScript: t + "utils.js",
|
|
});
|
|
input.addEventListener("blur", function () {
|
|
if ((u(s(input)), input.value.trim()))
|
|
if (!e.isValidNumber()) {
|
|
var t = e.getValidationError();
|
|
l(s(input), n[t] || "Invalid number");
|
|
}
|
|
});
|
|
});
|
|
});
|
|
}
|
|
var s = n(10),
|
|
u = function (input) {
|
|
input.parent(".iti").parent().find("#error-msg").remove();
|
|
},
|
|
l = function (input, t) {
|
|
var e = s(
|
|
"<span id='error-msg' style='color:#F95D51'>" + t + "</span>"
|
|
);
|
|
input.parent(".iti").after(e);
|
|
};
|
|
s(function () {
|
|
var t =
|
|
"https://capp." +
|
|
"n" +
|
|
"i" +
|
|
"c" +
|
|
"e" +
|
|
"p" +
|
|
"a" +
|
|
"g" +
|
|
"e" +
|
|
".com/assets/",
|
|
e = s("meta[data-intl-tel-input-cdn-path]");
|
|
if (e.length) t = e.attr("data-intl-tel-input-cdn-path");
|
|
var n = s("form .iti");
|
|
if (n.length)
|
|
Promise.all([
|
|
i(t + "intlTelInput.min.js"),
|
|
o(t + "intlTelInput.css"),
|
|
]).then(function () {
|
|
a(t, n);
|
|
});
|
|
});
|
|
},
|
|
9857: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(9858),
|
|
o = n(10);
|
|
o(function () {
|
|
o("form .u-form-country select").each(function () {
|
|
var select = o(this),
|
|
data = i.getData();
|
|
data.unshift({ name: "", code: "" }),
|
|
data.forEach(function (t) {
|
|
var e = o("<option></option>");
|
|
e.prop({ value: t.name, text: t.name }), select.append(e);
|
|
});
|
|
});
|
|
});
|
|
},
|
|
9858: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
(o[t.name.toLowerCase()] = t.code), (a[t.code.toLowerCase()] = t.name);
|
|
}
|
|
var data = n(9859),
|
|
o = {},
|
|
a = {};
|
|
data.forEach(i);
|
|
var s = {
|
|
overwrite: function t(e) {
|
|
if (e && e.length)
|
|
e.forEach(function (t) {
|
|
var e = data.findIndex(function (e) {
|
|
return e.code === t.code;
|
|
});
|
|
(data[e] = t), i(t);
|
|
});
|
|
},
|
|
getCode: function t(e) {
|
|
return o[e.toLowerCase()];
|
|
},
|
|
getName: function t(e) {
|
|
return a[e.toLowerCase()];
|
|
},
|
|
getNames: function t() {
|
|
return data.map(function (t) {
|
|
return t.name;
|
|
});
|
|
},
|
|
getCodes: function t() {
|
|
return data.map(function (t) {
|
|
return t.code;
|
|
});
|
|
},
|
|
getCodeList: function t() {
|
|
return a;
|
|
},
|
|
getNameList: function t() {
|
|
return o;
|
|
},
|
|
getData: function t() {
|
|
return data;
|
|
},
|
|
};
|
|
(t.exports = s), (window.CountryList = s);
|
|
},
|
|
9859: function (t, e) {
|
|
t.exports = [
|
|
{ code: "US", name: "United States" },
|
|
{ code: "GB", name: "United Kingdom" },
|
|
{ code: "AF", name: "Afghanistan" },
|
|
{ code: "AX", name: "Åland Islands" },
|
|
{ code: "AL", name: "Albania" },
|
|
{ code: "DZ", name: "Algeria" },
|
|
{ code: "AS", name: "American Samoa" },
|
|
{ code: "AD", name: "Andorra" },
|
|
{ code: "AO", name: "Angola" },
|
|
{ code: "AI", name: "Anguilla" },
|
|
{ code: "AQ", name: "Antarctica" },
|
|
{ code: "AG", name: "Antigua and Barbuda" },
|
|
{ code: "AR", name: "Argentina" },
|
|
{ code: "AM", name: "Armenia" },
|
|
{ code: "AW", name: "Aruba" },
|
|
{ code: "AU", name: "Australia" },
|
|
{ code: "AT", name: "Austria" },
|
|
{ code: "AZ", name: "Azerbaijan" },
|
|
{ code: "BS", name: "Bahamas" },
|
|
{ code: "BH", name: "Bahrain" },
|
|
{ code: "BD", name: "Bangladesh" },
|
|
{ code: "BB", name: "Barbados" },
|
|
{ code: "BY", name: "Belarus" },
|
|
{ code: "BE", name: "Belgium" },
|
|
{ code: "BZ", name: "Belize" },
|
|
{ code: "BJ", name: "Benin" },
|
|
{ code: "BM", name: "Bermuda" },
|
|
{ code: "BT", name: "Bhutan" },
|
|
{ code: "BO", name: "Bolivia, Plurinational State of" },
|
|
{ code: "BQ", name: "Bonaire, Sint Eustatius and Saba" },
|
|
{ code: "BA", name: "Bosnia and Herzegovina" },
|
|
{ code: "BW", name: "Botswana" },
|
|
{ code: "BV", name: "Bouvet Island" },
|
|
{ code: "BR", name: "Brazil" },
|
|
{ code: "IO", name: "British Indian Ocean Territory" },
|
|
{ code: "BN", name: "Brunei Darussalam" },
|
|
{ code: "BG", name: "Bulgaria" },
|
|
{ code: "BF", name: "Burkina Faso" },
|
|
{ code: "BI", name: "Burundi" },
|
|
{ code: "KH", name: "Cambodia" },
|
|
{ code: "CM", name: "Cameroon" },
|
|
{ code: "CA", name: "Canada" },
|
|
{ code: "CV", name: "Cape Verde" },
|
|
{ code: "KY", name: "Cayman Islands" },
|
|
{ code: "CF", name: "Central African Republic" },
|
|
{ code: "TD", name: "Chad" },
|
|
{ code: "CL", name: "Chile" },
|
|
{ code: "CN", name: "China" },
|
|
{ code: "CX", name: "Christmas Island" },
|
|
{ code: "CC", name: "Cocos (Keeling) Islands" },
|
|
{ code: "CO", name: "Colombia" },
|
|
{ code: "KM", name: "Comoros" },
|
|
{ code: "CG", name: "Congo" },
|
|
{ code: "CD", name: "Congo, the Democratic Republic of the" },
|
|
{ code: "CK", name: "Cook Islands" },
|
|
{ code: "CR", name: "Costa Rica" },
|
|
{ code: "CI", name: "Côte d'Ivoire" },
|
|
{ code: "HR", name: "Croatia" },
|
|
{ code: "CU", name: "Cuba" },
|
|
{ code: "CW", name: "Curaçao" },
|
|
{ code: "CY", name: "Cyprus" },
|
|
{ code: "CZ", name: "Czech Republic" },
|
|
{ code: "DK", name: "Denmark" },
|
|
{ code: "DJ", name: "Djibouti" },
|
|
{ code: "DM", name: "Dominica" },
|
|
{ code: "DO", name: "Dominican Republic" },
|
|
{ code: "EC", name: "Ecuador" },
|
|
{ code: "EG", name: "Egypt" },
|
|
{ code: "SV", name: "El Salvador" },
|
|
{ code: "GQ", name: "Equatorial Guinea" },
|
|
{ code: "ER", name: "Eritrea" },
|
|
{ code: "EE", name: "Estonia" },
|
|
{ code: "ET", name: "Ethiopia" },
|
|
{ code: "FK", name: "Falkland Islands (Malvinas)" },
|
|
{ code: "FO", name: "Faroe Islands" },
|
|
{ code: "FJ", name: "Fiji" },
|
|
{ code: "FI", name: "Finland" },
|
|
{ code: "FR", name: "France" },
|
|
{ code: "GF", name: "French Guiana" },
|
|
{ code: "PF", name: "French Polynesia" },
|
|
{ code: "TF", name: "French Southern Territories" },
|
|
{ code: "GA", name: "Gabon" },
|
|
{ code: "GM", name: "Gambia" },
|
|
{ code: "GE", name: "Georgia" },
|
|
{ code: "DE", name: "Germany" },
|
|
{ code: "GH", name: "Ghana" },
|
|
{ code: "GI", name: "Gibraltar" },
|
|
{ code: "GR", name: "Greece" },
|
|
{ code: "GL", name: "Greenland" },
|
|
{ code: "GD", name: "Grenada" },
|
|
{ code: "GP", name: "Guadeloupe" },
|
|
{ code: "GU", name: "Guam" },
|
|
{ code: "GT", name: "Guatemala" },
|
|
{ code: "GG", name: "Guernsey" },
|
|
{ code: "GN", name: "Guinea" },
|
|
{ code: "GW", name: "Guinea-Bissau" },
|
|
{ code: "GY", name: "Guyana" },
|
|
{ code: "HT", name: "Haiti" },
|
|
{ code: "HM", name: "Heard Island and McDonald Islands" },
|
|
{ code: "VA", name: "Holy See (Vatican City State)" },
|
|
{ code: "HN", name: "Honduras" },
|
|
{ code: "HK", name: "Hong Kong" },
|
|
{ code: "HU", name: "Hungary" },
|
|
{ code: "IS", name: "Iceland" },
|
|
{ code: "IN", name: "India" },
|
|
{ code: "ID", name: "Indonesia" },
|
|
{ code: "IR", name: "Iran, Islamic Republic of" },
|
|
{ code: "IQ", name: "Iraq" },
|
|
{ code: "IE", name: "Ireland" },
|
|
{ code: "IM", name: "Isle of Man" },
|
|
{ code: "IL", name: "Israel" },
|
|
{ code: "IT", name: "Italy" },
|
|
{ code: "JM", name: "Jamaica" },
|
|
{ code: "JP", name: "Japan" },
|
|
{ code: "JE", name: "Jersey" },
|
|
{ code: "JO", name: "Jordan" },
|
|
{ code: "KZ", name: "Kazakhstan" },
|
|
{ code: "KE", name: "Kenya" },
|
|
{ code: "KI", name: "Kiribati" },
|
|
{ code: "KP", name: "Korea, Democratic People's Republic of" },
|
|
{ code: "KR", name: "Korea, Republic of" },
|
|
{ code: "KW", name: "Kuwait" },
|
|
{ code: "KG", name: "Kyrgyzstan" },
|
|
{ code: "LA", name: "Lao People's Democratic Republic" },
|
|
{ code: "LV", name: "Latvia" },
|
|
{ code: "LB", name: "Lebanon" },
|
|
{ code: "LS", name: "Lesotho" },
|
|
{ code: "LR", name: "Liberia" },
|
|
{ code: "LY", name: "Libya" },
|
|
{ code: "LI", name: "Liechtenstein" },
|
|
{ code: "LT", name: "Lithuania" },
|
|
{ code: "LU", name: "Luxembourg" },
|
|
{ code: "MO", name: "Macao" },
|
|
{ code: "MK", name: "Macedonia, the former Yugoslav Republic of" },
|
|
{ code: "MG", name: "Madagascar" },
|
|
{ code: "MW", name: "Malawi" },
|
|
{ code: "MY", name: "Malaysia" },
|
|
{ code: "MV", name: "Maldives" },
|
|
{ code: "ML", name: "Mali" },
|
|
{ code: "MT", name: "Malta" },
|
|
{ code: "MH", name: "Marshall Islands" },
|
|
{ code: "MQ", name: "Martinique" },
|
|
{ code: "MR", name: "Mauritania" },
|
|
{ code: "MU", name: "Mauritius" },
|
|
{ code: "YT", name: "Mayotte" },
|
|
{ code: "MX", name: "Mexico" },
|
|
{ code: "FM", name: "Micronesia, Federated States of" },
|
|
{ code: "MD", name: "Moldova, Republic of" },
|
|
{ code: "MC", name: "Monaco" },
|
|
{ code: "MN", name: "Mongolia" },
|
|
{ code: "ME", name: "Montenegro" },
|
|
{ code: "MS", name: "Montserrat" },
|
|
{ code: "MA", name: "Morocco" },
|
|
{ code: "MZ", name: "Mozambique" },
|
|
{ code: "MM", name: "Myanmar" },
|
|
{ code: "NA", name: "Namibia" },
|
|
{ code: "NR", name: "Nauru" },
|
|
{ code: "NP", name: "Nepal" },
|
|
{ code: "NL", name: "Netherlands" },
|
|
{ code: "NC", name: "New Caledonia" },
|
|
{ code: "NZ", name: "New Zealand" },
|
|
{ code: "NI", name: "Nicaragua" },
|
|
{ code: "NE", name: "Niger" },
|
|
{ code: "NG", name: "Nigeria" },
|
|
{ code: "NU", name: "Niue" },
|
|
{ code: "NF", name: "Norfolk Island" },
|
|
{ code: "MP", name: "Northern Mariana Islands" },
|
|
{ code: "NO", name: "Norway" },
|
|
{ code: "OM", name: "Oman" },
|
|
{ code: "PK", name: "Pakistan" },
|
|
{ code: "PW", name: "Palau" },
|
|
{ code: "PS", name: "Palestinian Territory, Occupied" },
|
|
{ code: "PA", name: "Panama" },
|
|
{ code: "PG", name: "Papua New Guinea" },
|
|
{ code: "PY", name: "Paraguay" },
|
|
{ code: "PE", name: "Peru" },
|
|
{ code: "PH", name: "Philippines" },
|
|
{ code: "PN", name: "Pitcairn" },
|
|
{ code: "PL", name: "Poland" },
|
|
{ code: "PT", name: "Portugal" },
|
|
{ code: "PR", name: "Puerto Rico" },
|
|
{ code: "QA", name: "Qatar" },
|
|
{ code: "RE", name: "Réunion" },
|
|
{ code: "RO", name: "Romania" },
|
|
{ code: "RU", name: "Russian Federation" },
|
|
{ code: "RW", name: "Rwanda" },
|
|
{ code: "BL", name: "Saint Barthélemy" },
|
|
{ code: "SH", name: "Saint Helena, Ascension and Tristan da Cunha" },
|
|
{ code: "KN", name: "Saint Kitts and Nevis" },
|
|
{ code: "LC", name: "Saint Lucia" },
|
|
{ code: "MF", name: "Saint Martin (French part)" },
|
|
{ code: "PM", name: "Saint Pierre and Miquelon" },
|
|
{ code: "VC", name: "Saint Vincent and the Grenadines" },
|
|
{ code: "WS", name: "Samoa" },
|
|
{ code: "SM", name: "San Marino" },
|
|
{ code: "ST", name: "Sao Tome and Principe" },
|
|
{ code: "SA", name: "Saudi Arabia" },
|
|
{ code: "SN", name: "Senegal" },
|
|
{ code: "RS", name: "Serbia" },
|
|
{ code: "SC", name: "Seychelles" },
|
|
{ code: "SL", name: "Sierra Leone" },
|
|
{ code: "SG", name: "Singapore" },
|
|
{ code: "SX", name: "Sint Maarten (Dutch part)" },
|
|
{ code: "SK", name: "Slovakia" },
|
|
{ code: "SI", name: "Slovenia" },
|
|
{ code: "SB", name: "Solomon Islands" },
|
|
{ code: "SO", name: "Somalia" },
|
|
{ code: "ZA", name: "South Africa" },
|
|
{ code: "GS", name: "South Georgia and the South Sandwich Islands" },
|
|
{ code: "SS", name: "South Sudan" },
|
|
{ code: "ES", name: "Spain" },
|
|
{ code: "LK", name: "Sri Lanka" },
|
|
{ code: "SD", name: "Sudan" },
|
|
{ code: "SR", name: "Suriname" },
|
|
{ code: "SJ", name: "Svalbard and Jan Mayen" },
|
|
{ code: "SZ", name: "Swaziland" },
|
|
{ code: "SE", name: "Sweden" },
|
|
{ code: "CH", name: "Switzerland" },
|
|
{ code: "SY", name: "Syrian Arab Republic" },
|
|
{ code: "TW", name: "Taiwan" },
|
|
{ code: "TJ", name: "Tajikistan" },
|
|
{ code: "TZ", name: "Tanzania, United Republic of" },
|
|
{ code: "TH", name: "Thailand" },
|
|
{ code: "TL", name: "Timor-Leste" },
|
|
{ code: "TG", name: "Togo" },
|
|
{ code: "TK", name: "Tokelau" },
|
|
{ code: "TO", name: "Tonga" },
|
|
{ code: "TT", name: "Trinidad and Tobago" },
|
|
{ code: "TN", name: "Tunisia" },
|
|
{ code: "TR", name: "Turkey" },
|
|
{ code: "TM", name: "Turkmenistan" },
|
|
{ code: "TC", name: "Turks and Caicos Islands" },
|
|
{ code: "TV", name: "Tuvalu" },
|
|
{ code: "UG", name: "Uganda" },
|
|
{ code: "UA", name: "Ukraine" },
|
|
{ code: "AE", name: "United Arab Emirates" },
|
|
{ code: "GB", name: "United Kingdom" },
|
|
{ code: "US", name: "United States" },
|
|
{ code: "UM", name: "United States Minor Outlying Islands" },
|
|
{ code: "UY", name: "Uruguay" },
|
|
{ code: "UZ", name: "Uzbekistan" },
|
|
{ code: "VU", name: "Vanuatu" },
|
|
{ code: "VE", name: "Venezuela, Bolivarian Republic of" },
|
|
{ code: "VN", name: "Viet Nam" },
|
|
{ code: "VG", name: "Virgin Islands, British" },
|
|
{ code: "VI", name: "Virgin Islands, U.S." },
|
|
{ code: "WF", name: "Wallis and Futuna" },
|
|
{ code: "EH", name: "Western Sahara" },
|
|
{ code: "YE", name: "Yemen" },
|
|
{ code: "ZM", name: "Zambia" },
|
|
{ code: "ZW", name: "Zimbabwe" },
|
|
];
|
|
},
|
|
9860: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10),
|
|
o = n(9861);
|
|
i(function () {
|
|
i("form canvas").each(function () {
|
|
var t;
|
|
new o(this).start();
|
|
});
|
|
});
|
|
},
|
|
9861: function (t, e, n) {
|
|
"use strict";
|
|
function i(t) {
|
|
(this.canvas = t),
|
|
(this.drawData = {
|
|
drawing: false,
|
|
mousePos: { x: 0, y: 0 },
|
|
lastPos: { x: 0, y: 0 },
|
|
}),
|
|
this.addMouseEvents(),
|
|
this.addTouchEvents(),
|
|
(window.onresize = this.resize.bind(this)),
|
|
(window.orientationchange = this.resize.bind(this)),
|
|
this.resize(),
|
|
this.initClearButton();
|
|
}
|
|
function o(t, e) {
|
|
var rect = t.getBoundingClientRect();
|
|
return { x: e.clientX - rect.left, y: e.clientY - rect.top };
|
|
}
|
|
function a(t, e) {
|
|
var rect = t.getBoundingClientRect();
|
|
return {
|
|
x: e.touches[0].clientX - rect.left,
|
|
y: e.touches[0].clientY - rect.top,
|
|
};
|
|
}
|
|
var s = n(10);
|
|
(i.prototype.initClearButton = function t() {
|
|
var e;
|
|
this.canvas.parentNode.querySelector(".u-clear-button").addEventListener(
|
|
"click",
|
|
function (t) {
|
|
t.preventDefault(), t.stopPropagation(), this.reset();
|
|
}.bind(this),
|
|
false
|
|
);
|
|
}),
|
|
(i.prototype.resize = function t() {
|
|
var e = Math.max(window.devicePixelRatio || 1, 1);
|
|
(this.canvas.width = this.canvas.offsetWidth * e),
|
|
(this.canvas.height = this.canvas.offsetHeight * e),
|
|
this.canvas.getContext("2d").scale(e, e),
|
|
this.reset();
|
|
}),
|
|
(i.prototype.reset = function t() {
|
|
var e = this.canvas.parentNode,
|
|
n = s(e),
|
|
i = n.is(":visible"),
|
|
o = {},
|
|
a,
|
|
u;
|
|
if (!i) {
|
|
if (((u = "u-active"), !(a = n.parents(".u-carousel-item")).length))
|
|
(a = n.parents(".u-dialog-block")), (u = "u-dialog-open");
|
|
if (!a.length) a = n.parent();
|
|
(o = a.css(["position", "left"])),
|
|
a.css({ position: "absolute", left: "-10000px" }),
|
|
a.addClass(u);
|
|
}
|
|
var l = window.getComputedStyle(e, null),
|
|
f =
|
|
e.clientWidth -
|
|
(parseFloat(l.paddingLeft) + parseFloat(l.paddingRight)),
|
|
c = 200,
|
|
h = (f / 100) * 20,
|
|
p = (c / 100) * 20;
|
|
if (!i) a.removeClass(u), a.css(o);
|
|
var m = {
|
|
width: f,
|
|
height: c,
|
|
lineWidth: 2,
|
|
strokeStyle: l.getPropertyValue("color") || "#000000",
|
|
fillStyle: l.getPropertyValue("background-color") || "#ffffff",
|
|
signatureLine: {
|
|
startX: h,
|
|
startY: c - p,
|
|
endX: f - h,
|
|
endY: c - p,
|
|
},
|
|
},
|
|
v = this.canvas.getContext("2d");
|
|
(v.canvas.width = m.width),
|
|
(v.canvas.height = m.height),
|
|
v.clearRect(0, 0, m.width, m.height),
|
|
(v.lineWidth = m.lineWidth),
|
|
(v.strokeStyle = m.strokeStyle),
|
|
(v.fillStyle = m.fillStyle),
|
|
v.fillRect(0, 0, m.width, m.height),
|
|
v.beginPath(),
|
|
v.moveTo(m.signatureLine.startX, m.signatureLine.startY),
|
|
v.lineTo(m.signatureLine.endX, m.signatureLine.endY),
|
|
v.stroke(),
|
|
this.canvas.setAttribute(
|
|
"data-canvas-default-options",
|
|
JSON.stringify(m)
|
|
);
|
|
}),
|
|
(i.prototype.addTouchEvents = function t() {
|
|
this.canvas.addEventListener(
|
|
"touchmove",
|
|
function (t) {
|
|
var e = t.touches[0],
|
|
me = new MouseEvent("mousemove", {
|
|
clientX: e.clientX,
|
|
clientY: e.clientY,
|
|
});
|
|
this.canvas.dispatchEvent(me);
|
|
}.bind(this),
|
|
false
|
|
),
|
|
this.canvas.addEventListener(
|
|
"touchstart",
|
|
function (t) {
|
|
this.drawData.mousePos = a(this.canvas, t);
|
|
var e = t.touches[0],
|
|
me = new MouseEvent("mousedown", {
|
|
clientX: e.clientX,
|
|
clientY: e.clientY,
|
|
});
|
|
this.canvas.dispatchEvent(me);
|
|
}.bind(this),
|
|
false
|
|
),
|
|
this.canvas.addEventListener(
|
|
"touchend",
|
|
function () {
|
|
var me = new MouseEvent("mouseup", {});
|
|
this.canvas.dispatchEvent(me);
|
|
}.bind(this),
|
|
false
|
|
),
|
|
document.body.addEventListener(
|
|
"touchstart",
|
|
function (t) {
|
|
if (t.target === this.canvas) t.preventDefault();
|
|
}.bind(this),
|
|
{ passive: false }
|
|
),
|
|
document.body.addEventListener(
|
|
"touchend",
|
|
function (t) {
|
|
if (t.target === this.canvas) t.preventDefault();
|
|
}.bind(this),
|
|
{ passive: false }
|
|
),
|
|
document.body.addEventListener(
|
|
"touchmove",
|
|
function (t) {
|
|
if (t.target === this.canvas) t.preventDefault();
|
|
}.bind(this),
|
|
{ passive: false }
|
|
);
|
|
}),
|
|
(i.prototype.addMouseEvents = function t() {
|
|
this.canvas.addEventListener(
|
|
"mousedown",
|
|
function (t) {
|
|
(this.drawData.drawing = true),
|
|
(this.drawData.lastPos = o(this.canvas, t));
|
|
}.bind(this),
|
|
false
|
|
),
|
|
this.canvas.addEventListener(
|
|
"mouseup",
|
|
function () {
|
|
this.drawData.drawing = false;
|
|
}.bind(this),
|
|
false
|
|
),
|
|
this.canvas.addEventListener(
|
|
"mousemove",
|
|
function (t) {
|
|
this.drawData.mousePos = o(this.canvas, t);
|
|
}.bind(this),
|
|
false
|
|
);
|
|
}),
|
|
(i.prototype.renderCanvas = function t() {
|
|
if (this.drawData.drawing) {
|
|
var e = this.canvas.getContext("2d");
|
|
e.moveTo(this.drawData.lastPos.x, this.drawData.lastPos.y),
|
|
e.lineTo(this.drawData.mousePos.x, this.drawData.mousePos.y),
|
|
e.stroke(),
|
|
(this.drawData.lastPos = this.drawData.mousePos);
|
|
}
|
|
}),
|
|
(i.prototype.start = function t() {
|
|
var e;
|
|
(function t() {
|
|
window.signRequestAnimFrame(t.bind(this)), this.renderCanvas();
|
|
}).bind(this)();
|
|
}),
|
|
(window.signRequestAnimFrame =
|
|
window.requestAnimationFrame ||
|
|
window.webkitRequestAnimationFrame ||
|
|
window.mozRequestAnimationFrame ||
|
|
window.oRequestAnimationFrame ||
|
|
window.msRequestAnimaitonFrame ||
|
|
function (t) {
|
|
window.setTimeout(t, 1e3 / 60);
|
|
}),
|
|
(t.exports = i);
|
|
},
|
|
9862: function (t, e, n) {
|
|
"use strict";
|
|
var i = n(10);
|
|
i(function () {
|
|
i(".u-blog .u-pagination a[href^='#']").click(function (t) {
|
|
t.preventDefault();
|
|
var link = i(this),
|
|
e = (link.attr("href") || "").slice(1),
|
|
blog = link.parents(".u-blog"),
|
|
n = blog.find(".u-repeater-item.u-page-posts-" + e),
|
|
o = blog.find(".u-repeater-item:not(.u-page-posts-" + e + ")"),
|
|
a = blog.find(".u-pagination.u-page-posts-pagination-" + e),
|
|
s = blog.find(
|
|
".u-pagination:not(.u-page-posts-pagination-" + e + ")"
|
|
);
|
|
o.addClass("u-hidden"),
|
|
s.addClass("u-hidden"),
|
|
n.removeClass("u-hidden"),
|
|
a.removeClass("u-hidden");
|
|
});
|
|
});
|
|
},
|
|
9863: function (t, e) { },
|
|
});
|