registers-react-library
Version:
A library of React components for ONS registers projects, using the external ONS pattern library.
900 lines (898 loc) • 157 kB
JavaScript
(function (global, factory) {
if (typeof define === "function" && define.amd) {
define(["module"], factory);
} else if (typeof exports !== "undefined") {
factory(module);
} else {
var mod = {
exports: {}
};
factory(mod);
global.ons_js = mod.exports;
}
})(this, function (module) {
"use strict";
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
return typeof obj;
} : function (obj) {
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
};
function setDisplay() {
$(".js--hide").hide(), $(".js--show").show(), $(".nojs--hide").removeClass("nojs--hide");
}function clearViewportSizes() {
$("body").removeClass("viewport-sm viewport-md viewport-lg");
}function jsEnhanceViewportSize() {
$.each($(".js-viewport-size"), function () {
if ($(this).is(":visible")) {
clearViewportSizes();var e = $(this).attr("id");$("body").addClass(e);
}
});
}function toggleSubnav(e) {
e.toggleClass("js-expandable-active").find(".js-expandable__content").toggleClass("js-nav-hidden");
}function expandSubnav(e) {
e.hasClass("js-expandable-active") || e.addClass("js-expandable-active").find(".js-expandable__content").removeClass("js-nav-hidden");
}function collapseSubnav(e) {
e.hasClass("js-expandable-active") && e.removeClass("js-expandable-active").find(".js-expandable__content").addClass("js-nav-hidden");
}function showMenu(e, t) {
e.addClass("menu-is-expanded"), t.removeClass("nav-main--hidden"), t.attr("aria-expanded", !0);
}function hideMenu(e, t) {
e.removeClass("menu-is-expanded"), t.addClass("nav-main--hidden"), t.attr("aria-expanded", !1);
}function showSearch(e, t) {
e.addClass("search-is-expanded"), e.find(".nav--controls__icon").removeClass("icon-search-1").addClass("icon-cancel"), e.find(".nav--controls__text").text("Hide"), t.removeClass("nav-search--hidden"), t.attr("aria-expanded", !0);
}function hideSearch(e, t) {
e.removeClass("search-is-expanded"), e.find(".nav--controls__icon").removeClass("icon-cancel").addClass("icon-search-1"), e.find(".nav--controls__text").text("Search"), t.addClass("nav-search--hidden"), t.attr("aria-expanded", !1);
}function cloneSecondaryNav() {
var e = $(".js-nav-clone__link");$("body").hasClass("viewport-sm") && $(".js-nav-clone__list").find(e).length > 0 ? e.each(function () {
$(this).removeClass("secondary-nav__link").insertAfter(".primary-nav__item:last").addClass("primary-nav__link col").wrap('<li class="primary-nav__item">');
}) : !$("body").hasClass("viewport-sm") && $(".secondary-nav__item").is(":hidden") && e.each(function (e) {
var t = e + 1;$(this).unwrap().removeClass("primary-nav__link col").addClass("secondary-nav__link").appendTo(".js-nav-clone__list li:nth-child(" + t + ")");
});
}function clonePrimaryItems() {
var e = $(".js-nav__duplicate");$("body").hasClass("viewport-sm") && 0 == e.length ? $(".js-expandable").each(function () {
var e = $(this),
t = e.find("a:first").attr("href"),
n = e.find("a:first").html(),
r = e.find(".js-expandable__content"),
i = '<a class="primary-nav__child-link" href="' + t + '">' + n + "</a>",
o = '<li class="primary-nav__child-item js-nav__duplicate js-expandable__child">' + i + "</li>";r.prepend(o);
}) : !$("body").hasClass("viewport-sm") && e.length > 0 && e.remove();
}function cloneLanguageToggle() {
var e = $(".language--js"),
t = $(".language--js__container"),
n = "margin-top-sm--1 margin-bottom-sm--4 margin-left-sm--1";$("body").hasClass("viewport-sm") && 0 == $("#nav-primary").find(e).length ? e.appendTo("#nav-primary").addClass(n) : !$("body").hasClass("viewport-sm") && $("#nav-primary").find(e).length > 0 && e.appendTo(t).removeClass(n);
}function showHide(e) {
var t = $(".js-show-hide .js-show-hide__title");t.length > 0 && t.each(function (t) {
var n = $(this),
r = n.next(),
i = n.children("button");if (e) {
n.children("button").attr("aria-expanded", "true"), r.attr("aria-hidden", "false");n.children("button").contents().unwrap();
} else {
var o = "collapsible-" + n.index();if (n.hasClass("is-shown")) var s = !1;else var s = !0;n.nextUntil(".js-show-hide__title").attr({ id: o, "aria-hidden": s }), s = !s, 0 == i.length && n.wrapInner('<button class="js-show-hide__button" type="button" aria-expanded="' + s + '" aria-controls="' + o + '">'), i = n.children("button"), i.on("click", function () {
var e = $(this),
t = "false" === e.attr("aria-expanded");e.attr("aria-expanded", t), r.attr("aria-hidden", !t), setTimeout(function () {
$("ol").css("counter-reset", "item");
}, 1);
});
}
});
}function forceShow(e) {
e.find(".js-show-hide__title button").attr("aria-expanded", "true"), e.find(".js-show-hide__content").attr("aria-hidden", "false");
}function datepicker(e, t, n) {
this.id = e, this.$id = $("#" + e), this.$monthObj = this.$id.find(".js-datepicker__month"), this.$prev = this.$id.find(".js-datepicker__prev"), this.$next = this.$id.find(".js-datepicker__next"), this.$grid = this.$id.find(".js-datepicker__grid"), this.$target = $("#" + t + " input"), this.$clear = this.$id.find(".js-datepicker__clear"), this.bModal = n, this.monthNames = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], this.dayNames = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], this.dateObj = new Date(), this.curYear = this.dateObj.getFullYear(), this.year = this.curYear, this.curMonth = this.dateObj.getMonth(), this.month = this.curMonth, this.currentDate = !0, this.day = !1, this.date = this.dateObj.getDate(), this.keys = { tab: 9, enter: 13, esc: 27, space: 32, pageup: 33, pagedown: 34, end: 35, home: 36, left: 37, up: 38, right: 39, down: 40 }, this.handleDateChange(), this.popGrid(), this.$grid.attr("aria-activedescendant", this.$grid.find(".today").attr("id")), this.bindHandlers(), 1 == this.bModal && this.$id.attr("aria-hidden", "true");
}function mobileFilters() {
var e = $(".js-mobile-filters"),
t = $(".js-mobile-filters__title"),
n = $(".js-mobile-filters__contents"),
r = e.find("a#clear-search"),
i = $(".js-mobile-filters__sort");e.addClass("js-show-hide show-hide show-hide--light").removeClass("tiles__item tiles__item--nav-type"), t.addClass("mobile-filters__title js-show-hide__title show-hide__title").removeClass("tiles__title-h3 tiles__title-h3--nav"), n.addClass("mobile-filters__contents js-show-hide__contents").removeClass("tiles__content tiles__content--nav"), r.prependTo(n), i.prependTo(n).css("display", "inline-block");
}function setEqualHeights() {
if ($("body").is(".viewport-md, .viewport-lg")) {
var e = 0,
t = $(".js-equal-height");t.each(function () {
$(this).height() > e && (e = $(this).height());
}), t.height(e);
}
}function hoverState() {
function e(e) {
var t,
n,
r,
i = e.attr("class"),
o = 0;for (o; o < u; o++) {
var s = l[o],
a = s.class1,
d = s.class2;i.indexOf(a) >= 0 && (i = i.replace(a, d)), t = e.find("." + a), n = t.length, n && (r = t.attr("class"), t.attr("class", r + " js-hover-click--child"));
}e.attr("class", i), $(".js-hover-click--child").each(function (e) {
var t = $(this);c[e] = t.attr("class"), $(l).each(function (e) {
var n = l[e],
r = n.class1,
i = n.class2;if (t.hasClass(r)) {
var o = t.attr("class");o = o.replace(r, i), t.attr("class", o);
}
});
});
}function t(e, t) {
e.attr("class", t);
}function n(e) {
$(".js-hover-click--child").each(function (t) {
$(this).attr("class", e[t].replace(/\ js-hover-click--child/g, ""));
});
}var r,
i = $(".js-hover-click"),
o = i.find("a:first"),
s = null,
a = null,
c = [];if (!i.length) return !1;i.each(function () {
var e = $(this);e.css("position", "relative"), o = e.find("a:first"), o.append('<span class="box__clickable"></span>');
});var l = [];l.push({ class1: "background--white", class2: "background--ship-grey" }), l.push({ class1: "background--gallery", class2: "background--nevada" }), l.push({ class1: "background--mercury", class2: "background--ship-grey" }), l.push({ class1: "background--iron-light", class2: "background--ship-grey" }), l.push({ class1: "border-top--iron-sm", class2: "border-top--thunder-sm" }), l.push({ class1: "border-top--iron-md", class2: "border-top--thunder-md" }), l.push({ class1: "border-top--iron-light-sm", class2: "border-top--thunder-sm" }), l.push({ class1: "border-top--iron-light-md", class2: "border-top--thunder-md" }), l.push({ class1: "border-right--iron-light-sm", class2: "border-right--thunder-sm" }), l.push({ class1: "border-right--iron-light-md", class2: "border-right--thunder-md" }), l.push({ class1: "border-bottom--iron-light-sm", class2: "border-bottom--thunder-sm" }), l.push({ class1: "border-bottom--iron-light-md", class2: "border-bottom--thunder-md" }), l.push({ class1: "border-left--iron-light-sm", class2: "border-left--thunder-sm" }), l.push({ class1: "border-left--iron-light-md", class2: "border-left--thunder-md" }), l.push({ class1: "icon-arrow-right--dark", class2: "icon-arrow-right--light" }), l.push({ class1: "image-background", class2: "image-background--mercury" });var u = l.length;i.hover(function () {
if (!a) {
var t = $(this);r = t.attr("class"), e(t), s = !0;
}
}, function () {
a || (t($(this), r), n(c), s = null);
}), i.find("a").focus(function () {
if (!s) {
var r = $(this).closest(i),
o = r.attr("class");r.parent(i).length && (e(r), a = !0, r.focusout(function () {
t($(this), o), n(c), a = null;
}));
}
});
}function addLoadingOverlay() {
var e = document.getElementsByTagName("body")[0],
t = document.createElement("div");t.id = "loading-overlay";var n = document.createElement("div");n.innerHTML = "<p>Loading...</p>", n.className = "loader print--hide", t.appendChild(n), e.appendChild(t);
}!function (e, t) {
"object" == (typeof module === "undefined" ? "undefined" : _typeof(module)) && "object" == _typeof(module.exports) ? module.exports = e.document ? t(e, !0) : function (e) {
if (!e.document) throw new Error("jQuery requires a window with a document");return t(e);
} : t(e);
}("undefined" != typeof window ? window : undefined, function (e, t) {
function n(e) {
var t = "length" in e && e.length,
n = Z.type(e);return "function" !== n && !Z.isWindow(e) && (!(1 !== e.nodeType || !t) || "array" === n || 0 === t || "number" == typeof t && t > 0 && t - 1 in e);
}function r(e, t, n) {
if (Z.isFunction(t)) return Z.grep(e, function (e, r) {
return !!t.call(e, r, e) !== n;
});if (t.nodeType) return Z.grep(e, function (e) {
return e === t !== n;
});if ("string" == typeof t) {
if (ie.test(t)) return Z.filter(t, e, n);t = Z.filter(t, e);
}return Z.grep(e, function (e) {
return Y.call(t, e) >= 0 !== n;
});
}function i(e, t) {
for (; (e = e[t]) && 1 !== e.nodeType;) {}return e;
}function o(e) {
var t = ue[e] = {};return Z.each(e.match(le) || [], function (e, n) {
t[n] = !0;
}), t;
}function s() {
J.removeEventListener("DOMContentLoaded", s, !1), e.removeEventListener("load", s, !1), Z.ready();
}function a() {
Object.defineProperty(this.cache = {}, 0, { get: function get() {
return {};
} }), this.expando = Z.expando + a.uid++;
}function c(e, t, n) {
var r;if (void 0 === n && 1 === e.nodeType) if (r = "data-" + t.replace(ve, "-$1").toLowerCase(), "string" == typeof (n = e.getAttribute(r))) {
try {
n = "true" === n || "false" !== n && ("null" === n ? null : +n + "" === n ? +n : ge.test(n) ? Z.parseJSON(n) : n);
} catch (e) {}pe.set(e, t, n);
} else n = void 0;return n;
}function l() {
return !0;
}function u() {
return !1;
}function d() {
try {
return J.activeElement;
} catch (e) {}
}function h(e, t) {
return Z.nodeName(e, "table") && Z.nodeName(11 !== t.nodeType ? t : t.firstChild, "tr") ? e.getElementsByTagName("tbody")[0] || e.appendChild(e.ownerDocument.createElement("tbody")) : e;
}function f(e) {
return e.type = (null !== e.getAttribute("type")) + "/" + e.type, e;
}function p(e) {
var t = Ae.exec(e.type);return t ? e.type = t[1] : e.removeAttribute("type"), e;
}function g(e, t) {
for (var n = 0, r = e.length; r > n; n++) {
fe.set(e[n], "globalEval", !t || fe.get(t[n], "globalEval"));
}
}function v(e, t) {
var n, r, i, o, s, a, c, l;if (1 === t.nodeType) {
if (fe.hasData(e) && (o = fe.access(e), s = fe.set(t, o), l = o.events)) {
delete s.handle, s.events = {};for (i in l) {
for (n = 0, r = l[i].length; r > n; n++) {
Z.event.add(t, i, l[i][n]);
}
}
}pe.hasData(e) && (a = pe.access(e), c = Z.extend({}, a), pe.set(t, c));
}
}function m(e, t) {
var n = e.getElementsByTagName ? e.getElementsByTagName(t || "*") : e.querySelectorAll ? e.querySelectorAll(t || "*") : [];return void 0 === t || t && Z.nodeName(e, t) ? Z.merge([e], n) : n;
}function y(e, t) {
var n = t.nodeName.toLowerCase();"input" === n && xe.test(e.type) ? t.checked = e.checked : ("input" === n || "textarea" === n) && (t.defaultValue = e.defaultValue);
}function b(t, n) {
var r,
i = Z(n.createElement(t)).appendTo(n.body),
o = e.getDefaultComputedStyle && (r = e.getDefaultComputedStyle(i[0])) ? r.display : Z.css(i[0], "display");return i.detach(), o;
}function x(e) {
var t = J,
n = qe[e];return n || (n = b(e, t), "none" !== n && n || (Le = (Le || Z("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement), t = Le[0].contentDocument, t.write(), t.close(), n = b(e, t), Le.detach()), qe[e] = n), n;
}function w(e, t, n) {
var r,
i,
o,
s,
a = e.style;return n = n || Oe(e), n && (s = n.getPropertyValue(t) || n[t]), n && ("" !== s || Z.contains(e.ownerDocument, e) || (s = Z.style(e, t)), Me.test(s) && He.test(t) && (r = a.width, i = a.minWidth, o = a.maxWidth, a.minWidth = a.maxWidth = a.width = s, s = n.width, a.width = r, a.minWidth = i, a.maxWidth = o)), void 0 !== s ? s + "" : s;
}function $(e, t) {
return { get: function get() {
return e() ? void delete this.get : (this.get = t).apply(this, arguments);
} };
}function k(e, t) {
if (t in e) return t;for (var n = t[0].toUpperCase() + t.slice(1), r = t, i = Ke.length; i--;) {
if ((t = Ke[i] + n) in e) return t;
}return r;
}function C(e, t, n) {
var r = Re.exec(t);return r ? Math.max(0, r[1] - (n || 0)) + (r[2] || "px") : t;
}function T(e, t, n, r, i) {
for (var o = n === (r ? "border" : "content") ? 4 : "width" === t ? 1 : 0, s = 0; 4 > o; o += 2) {
"margin" === n && (s += Z.css(e, n + ye[o], !0, i)), r ? ("content" === n && (s -= Z.css(e, "padding" + ye[o], !0, i)), "margin" !== n && (s -= Z.css(e, "border" + ye[o] + "Width", !0, i))) : (s += Z.css(e, "padding" + ye[o], !0, i), "padding" !== n && (s += Z.css(e, "border" + ye[o] + "Width", !0, i)));
}return s;
}function j(e, t, n) {
var r = !0,
i = "width" === t ? e.offsetWidth : e.offsetHeight,
o = Oe(e),
s = "border-box" === Z.css(e, "boxSizing", !1, o);if (0 >= i || null == i) {
if (i = w(e, t, o), (0 > i || null == i) && (i = e.style[t]), Me.test(i)) return i;r = s && (U.boxSizingReliable() || i === e.style[t]), i = parseFloat(i) || 0;
}return i + T(e, t, n || (s ? "border" : "content"), r, o) + "px";
}function _(e, t) {
for (var n, r, i, o = [], s = 0, a = e.length; a > s; s++) {
r = e[s], r.style && (o[s] = fe.get(r, "olddisplay"), n = r.style.display, t ? (o[s] || "none" !== n || (r.style.display = ""), "" === r.style.display && be(r) && (o[s] = fe.access(r, "olddisplay", x(r.nodeName)))) : (i = be(r), "none" === n && i || fe.set(r, "olddisplay", i ? n : Z.css(r, "display"))));
}for (s = 0; a > s; s++) {
r = e[s], r.style && (t && "none" !== r.style.display && "" !== r.style.display || (r.style.display = t ? o[s] || "" : "none"));
}return e;
}function N(e, t, n, r, i) {
return new N.prototype.init(e, t, n, r, i);
}function D() {
return setTimeout(function () {
ze = void 0;
}), ze = Z.now();
}function S(e, t) {
var n,
r = 0,
i = { height: e };for (t = t ? 1 : 0; 4 > r; r += 2 - t) {
n = ye[r], i["margin" + n] = i["padding" + n] = e;
}return t && (i.opacity = i.width = e), i;
}function E(e, t, n) {
for (var r, i = (Je[t] || []).concat(Je["*"]), o = 0, s = i.length; s > o; o++) {
if (r = i[o].call(n, t, e)) return r;
}
}function A(e, t, n) {
var r,
i,
o,
s,
a,
c,
l,
u = this,
d = {},
h = e.style,
f = e.nodeType && be(e),
p = fe.get(e, "fxshow");n.queue || (a = Z._queueHooks(e, "fx"), null == a.unqueued && (a.unqueued = 0, c = a.empty.fire, a.empty.fire = function () {
a.unqueued || c();
}), a.unqueued++, u.always(function () {
u.always(function () {
a.unqueued--, Z.queue(e, "fx").length || a.empty.fire();
});
})), 1 === e.nodeType && ("height" in t || "width" in t) && (n.overflow = [h.overflow, h.overflowX, h.overflowY], l = Z.css(e, "display"), "inline" === ("none" === l ? fe.get(e, "olddisplay") || x(e.nodeName) : l) && "none" === Z.css(e, "float") && (h.display = "inline-block")), n.overflow && (h.overflow = "hidden", u.always(function () {
h.overflow = n.overflow[0], h.overflowX = n.overflow[1], h.overflowY = n.overflow[2];
}));for (r in t) {
if (i = t[r], Ge.exec(i)) {
if (delete t[r], o = o || "toggle" === i, i === (f ? "hide" : "show")) {
if ("show" !== i || !p || void 0 === p[r]) continue;f = !0;
}d[r] = p && p[r] || Z.style(e, r);
} else l = void 0;
}if (Z.isEmptyObject(d)) "inline" === ("none" === l ? x(e.nodeName) : l) && (h.display = l);else {
p ? "hidden" in p && (f = p.hidden) : p = fe.access(e, "fxshow", {}), o && (p.hidden = !f), f ? Z(e).show() : u.done(function () {
Z(e).hide();
}), u.done(function () {
var t;fe.remove(e, "fxshow");for (t in d) {
Z.style(e, t, d[t]);
}
});for (r in d) {
s = E(f ? p[r] : 0, r, u), r in p || (p[r] = s.start, f && (s.end = s.start, s.start = "width" === r || "height" === r ? 1 : 0));
}
}
}function P(e, t) {
var n, r, i, o, s;for (n in e) {
if (r = Z.camelCase(n), i = t[r], o = e[n], Z.isArray(o) && (i = o[1], o = e[n] = o[0]), n !== r && (e[r] = o, delete e[n]), (s = Z.cssHooks[r]) && "expand" in s) {
o = s.expand(o), delete e[r];for (n in o) {
n in e || (e[n] = o[n], t[n] = i);
}
} else t[r] = i;
}
}function L(e, t, n) {
var r,
i,
o = 0,
s = Ue.length,
a = Z.Deferred().always(function () {
delete c.elem;
}),
c = function c() {
if (i) return !1;for (var t = ze || D(), n = Math.max(0, l.startTime + l.duration - t), r = n / l.duration || 0, o = 1 - r, s = 0, c = l.tweens.length; c > s; s++) {
l.tweens[s].run(o);
}return a.notifyWith(e, [l, o, n]), 1 > o && c ? n : (a.resolveWith(e, [l]), !1);
},
l = a.promise({ elem: e, props: Z.extend({}, t), opts: Z.extend(!0, { specialEasing: {} }, n), originalProperties: t, originalOptions: n, startTime: ze || D(), duration: n.duration, tweens: [], createTween: function createTween(t, n) {
var r = Z.Tween(e, l.opts, t, n, l.opts.specialEasing[t] || l.opts.easing);return l.tweens.push(r), r;
}, stop: function stop(t) {
var n = 0,
r = t ? l.tweens.length : 0;if (i) return this;for (i = !0; r > n; n++) {
l.tweens[n].run(1);
}return t ? a.resolveWith(e, [l, t]) : a.rejectWith(e, [l, t]), this;
} }),
u = l.props;for (P(u, l.opts.specialEasing); s > o; o++) {
if (r = Ue[o].call(l, e, u, l.opts)) return r;
}return Z.map(u, E, l), Z.isFunction(l.opts.start) && l.opts.start.call(e, l), Z.fx.timer(Z.extend(c, { elem: e, anim: l, queue: l.opts.queue })), l.progress(l.opts.progress).done(l.opts.done, l.opts.complete).fail(l.opts.fail).always(l.opts.always);
}function q(e) {
return function (t, n) {
"string" != typeof t && (n = t, t = "*");var r,
i = 0,
o = t.toLowerCase().match(le) || [];if (Z.isFunction(n)) for (; r = o[i++];) {
"+" === r[0] ? (r = r.slice(1) || "*", (e[r] = e[r] || []).unshift(n)) : (e[r] = e[r] || []).push(n);
}
};
}function H(e, t, n, r) {
function i(a) {
var c;return o[a] = !0, Z.each(e[a] || [], function (e, a) {
var l = a(t, n, r);return "string" != typeof l || s || o[l] ? s ? !(c = l) : void 0 : (t.dataTypes.unshift(l), i(l), !1);
}), c;
}var o = {},
s = e === ut;return i(t.dataTypes[0]) || !o["*"] && i("*");
}function M(e, t) {
var n,
r,
i = Z.ajaxSettings.flatOptions || {};for (n in t) {
void 0 !== t[n] && ((i[n] ? e : r || (r = {}))[n] = t[n]);
}return r && Z.extend(!0, e, r), e;
}function O(e, t, n) {
for (var r, i, o, s, a = e.contents, c = e.dataTypes; "*" === c[0];) {
c.shift(), void 0 === r && (r = e.mimeType || t.getResponseHeader("Content-Type"));
}if (r) for (i in a) {
if (a[i] && a[i].test(r)) {
c.unshift(i);break;
}
}if (c[0] in n) o = c[0];else {
for (i in n) {
if (!c[0] || e.converters[i + " " + c[0]]) {
o = i;break;
}s || (s = i);
}o = o || s;
}return o ? (o !== c[0] && c.unshift(o), n[o]) : void 0;
}function F(e, t, n, r) {
var i,
o,
s,
a,
c,
l = {},
u = e.dataTypes.slice();if (u[1]) for (s in e.converters) {
l[s.toLowerCase()] = e.converters[s];
}for (o = u.shift(); o;) {
if (e.responseFields[o] && (n[e.responseFields[o]] = t), !c && r && e.dataFilter && (t = e.dataFilter(t, e.dataType)), c = o, o = u.shift()) if ("*" === o) o = c;else if ("*" !== c && c !== o) {
if (!(s = l[c + " " + o] || l["* " + o])) for (i in l) {
if (a = i.split(" "), a[1] === o && (s = l[c + " " + a[0]] || l["* " + a[0]])) {
s === !0 ? s = l[i] : l[i] !== !0 && (o = a[0], u.unshift(a[1]));break;
}
}if (s !== !0) if (s && e.throws) t = s(t);else try {
t = s(t);
} catch (e) {
return { state: "parsererror", error: s ? e : "No conversion from " + c + " to " + o };
}
}
}return { state: "success", data: t };
}function R(e, t, n, r) {
var i;if (Z.isArray(t)) Z.each(t, function (t, i) {
n || pt.test(e) ? r(e, i) : R(e + "[" + ("object" == (typeof i === "undefined" ? "undefined" : _typeof(i)) ? t : "") + "]", i, n, r);
});else if (n || "object" !== Z.type(t)) r(e, t);else for (i in t) {
R(e + "[" + i + "]", t[i], n, r);
}
}function W(e) {
return Z.isWindow(e) ? e : 9 === e.nodeType && e.defaultView;
}var I = [],
B = I.slice,
K = I.concat,
z = I.push,
Y = I.indexOf,
G = {},
X = G.toString,
V = G.hasOwnProperty,
U = {},
J = e.document,
Q = "2.1.4",
Z = function Z(e, t) {
return new Z.fn.init(e, t);
},
ee = function ee(e, t) {
return t.toUpperCase();
};Z.fn = Z.prototype = { jquery: Q, constructor: Z, selector: "", length: 0, toArray: function toArray() {
return B.call(this);
}, get: function get(e) {
return null != e ? 0 > e ? this[e + this.length] : this[e] : B.call(this);
}, pushStack: function pushStack(e) {
var t = Z.merge(this.constructor(), e);return t.prevObject = this, t.context = this.context, t;
}, each: function each(e, t) {
return Z.each(this, e, t);
}, map: function map(e) {
return this.pushStack(Z.map(this, function (t, n) {
return e.call(t, n, t);
}));
}, slice: function slice() {
return this.pushStack(B.apply(this, arguments));
}, first: function first() {
return this.eq(0);
}, last: function last() {
return this.eq(-1);
}, eq: function eq(e) {
var t = this.length,
n = +e + (0 > e ? t : 0);return this.pushStack(n >= 0 && t > n ? [this[n]] : []);
}, end: function end() {
return this.prevObject || this.constructor(null);
}, push: z, sort: I.sort, splice: I.splice }, Z.extend = Z.fn.extend = function () {
var e,
t,
n,
r,
i,
o,
s = arguments[0] || {},
a = 1,
c = arguments.length,
l = !1;for ("boolean" == typeof s && (l = s, s = arguments[a] || {}, a++), "object" == (typeof s === "undefined" ? "undefined" : _typeof(s)) || Z.isFunction(s) || (s = {}), a === c && (s = this, a--); c > a; a++) {
if (null != (e = arguments[a])) for (t in e) {
n = s[t], r = e[t], s !== r && (l && r && (Z.isPlainObject(r) || (i = Z.isArray(r))) ? (i ? (i = !1, o = n && Z.isArray(n) ? n : []) : o = n && Z.isPlainObject(n) ? n : {}, s[t] = Z.extend(l, o, r)) : void 0 !== r && (s[t] = r));
}
}return s;
}, Z.extend({ expando: "jQuery" + (Q + Math.random()).replace(/\D/g, ""), isReady: !0, error: function error(e) {
throw new Error(e);
}, noop: function noop() {}, isFunction: function isFunction(e) {
return "function" === Z.type(e);
}, isArray: Array.isArray, isWindow: function isWindow(e) {
return null != e && e === e.window;
}, isNumeric: function isNumeric(e) {
return !Z.isArray(e) && e - parseFloat(e) + 1 >= 0;
}, isPlainObject: function isPlainObject(e) {
return "object" === Z.type(e) && !e.nodeType && !Z.isWindow(e) && !(e.constructor && !V.call(e.constructor.prototype, "isPrototypeOf"));
}, isEmptyObject: function isEmptyObject(e) {
var t;for (t in e) {
return !1;
}return !0;
}, type: function type(e) {
return null == e ? e + "" : "object" == (typeof e === "undefined" ? "undefined" : _typeof(e)) || "function" == typeof e ? G[X.call(e)] || "object" : typeof e === "undefined" ? "undefined" : _typeof(e);
}, globalEval: function globalEval(e) {
var t,
n = eval;(e = Z.trim(e)) && (1 === e.indexOf("use strict") ? (t = J.createElement("script"), t.text = e, J.head.appendChild(t).parentNode.removeChild(t)) : n(e));
}, camelCase: function camelCase(e) {
return e.replace(/^-ms-/, "ms-").replace(/-([\da-z])/gi, ee);
}, nodeName: function nodeName(e, t) {
return e.nodeName && e.nodeName.toLowerCase() === t.toLowerCase();
}, each: function each(e, t, r) {
var i = 0,
o = e.length,
s = n(e);if (r) {
if (s) for (; o > i && t.apply(e[i], r) !== !1; i++) {} else for (i in e) {
if (t.apply(e[i], r) === !1) break;
}
} else if (s) for (; o > i && t.call(e[i], i, e[i]) !== !1; i++) {} else for (i in e) {
if (t.call(e[i], i, e[i]) === !1) break;
}return e;
}, trim: function trim(e) {
return null == e ? "" : (e + "").replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
}, makeArray: function makeArray(e, t) {
var r = t || [];return null != e && (n(Object(e)) ? Z.merge(r, "string" == typeof e ? [e] : e) : z.call(r, e)), r;
}, inArray: function inArray(e, t, n) {
return null == t ? -1 : Y.call(t, e, n);
}, merge: function merge(e, t) {
for (var n = +t.length, r = 0, i = e.length; n > r; r++) {
e[i++] = t[r];
}return e.length = i, e;
}, grep: function grep(e, t, n) {
for (var r = [], i = 0, o = e.length, s = !n; o > i; i++) {
!t(e[i], i) !== s && r.push(e[i]);
}return r;
}, map: function map(e, t, r) {
var i,
o = 0,
s = e.length,
a = n(e),
c = [];if (a) for (; s > o; o++) {
null != (i = t(e[o], o, r)) && c.push(i);
} else for (o in e) {
null != (i = t(e[o], o, r)) && c.push(i);
}return K.apply([], c);
}, guid: 1, proxy: function proxy(e, t) {
var n, r, i;return "string" == typeof t && (n = e[t], t = e, e = n), Z.isFunction(e) ? (r = B.call(arguments, 2), i = function i() {
return e.apply(t || this, r.concat(B.call(arguments)));
}, i.guid = e.guid = e.guid || Z.guid++, i) : void 0;
}, now: Date.now, support: U }), Z.each("Boolean Number String Function Array Date RegExp Object Error".split(" "), function (e, t) {
G["[object " + t + "]"] = t.toLowerCase();
});var te = function (e) {
function t(e, t, n, r) {
var i, o, s, a, l, d, h, f, p, g;if ((t ? t.ownerDocument || t : O) !== S && D(t), t = t || S, n = n || [], a = t.nodeType, "string" != typeof e || !e || 1 !== a && 9 !== a && 11 !== a) return n;if (!r && A) {
if (11 !== a && (i = ve.exec(e))) if (s = i[1]) {
if (9 === a) {
if (!(o = t.getElementById(s)) || !o.parentNode) return n;if (o.id === s) return n.push(o), n;
} else if (t.ownerDocument && (o = t.ownerDocument.getElementById(s)) && H(t, o) && o.id === s) return n.push(o), n;
} else {
if (i[2]) return U.apply(n, t.getElementsByTagName(e)), n;if ((s = i[3]) && b.getElementsByClassName) return U.apply(n, t.getElementsByClassName(s)), n;
}if (b.qsa && (!P || !P.test(e))) {
if (f = h = M, p = t, g = 1 !== a && e, 1 === a && "object" !== t.nodeName.toLowerCase()) {
for (d = k(e), (h = t.getAttribute("id")) ? f = h.replace(ye, "\\$&") : t.setAttribute("id", f), f = "[id='" + f + "'] ", l = d.length; l--;) {
d[l] = f + u(d[l]);
}p = me.test(e) && c(t.parentNode) || t, g = d.join(",");
}if (g) try {
return U.apply(n, p.querySelectorAll(g)), n;
} catch (e) {} finally {
h || t.removeAttribute("id");
}
}
}return T(e.replace(se, "$1"), t, n, r);
}function n() {
function e(n, r) {
return t.push(n + " ") > x.cacheLength && delete e[t.shift()], e[n + " "] = r;
}var t = [];return e;
}function r(e) {
return e[M] = !0, e;
}function i(e) {
var t = S.createElement("div");try {
return !!e(t);
} catch (e) {
return !1;
} finally {
t.parentNode && t.parentNode.removeChild(t), t = null;
}
}function o(e, t) {
for (var n = e.split("|"), r = e.length; r--;) {
x.attrHandle[n[r]] = t;
}
}function s(e, t) {
var n = t && e,
r = n && 1 === e.nodeType && 1 === t.nodeType && (~t.sourceIndex || z) - (~e.sourceIndex || z);if (r) return r;if (n) for (; n = n.nextSibling;) {
if (n === t) return -1;
}return e ? 1 : -1;
}function a(e) {
return r(function (t) {
return t = +t, r(function (n, r) {
for (var i, o = e([], n.length, t), s = o.length; s--;) {
n[i = o[s]] && (n[i] = !(r[i] = n[i]));
}
});
});
}function c(e) {
return e && void 0 !== e.getElementsByTagName && e;
}function l() {}function u(e) {
for (var t = 0, n = e.length, r = ""; n > t; t++) {
r += e[t].value;
}return r;
}function d(e, t, n) {
var r = t.dir,
i = n && "parentNode" === r,
o = R++;return t.first ? function (t, n, o) {
for (; t = t[r];) {
if (1 === t.nodeType || i) return e(t, n, o);
}
} : function (t, n, s) {
var a,
c,
l = [F, o];if (s) {
for (; t = t[r];) {
if ((1 === t.nodeType || i) && e(t, n, s)) return !0;
}
} else for (; t = t[r];) {
if (1 === t.nodeType || i) {
if (c = t[M] || (t[M] = {}), (a = c[r]) && a[0] === F && a[1] === o) return l[2] = a[2];if (c[r] = l, l[2] = e(t, n, s)) return !0;
}
}
};
}function h(e) {
return e.length > 1 ? function (t, n, r) {
for (var i = e.length; i--;) {
if (!e[i](t, n, r)) return !1;
}return !0;
} : e[0];
}function f(e, n, r) {
for (var i = 0, o = n.length; o > i; i++) {
t(e, n[i], r);
}return r;
}function p(e, t, n, r, i) {
for (var o, s = [], a = 0, c = e.length, l = null != t; c > a; a++) {
(o = e[a]) && (!n || n(o, r, i)) && (s.push(o), l && t.push(a));
}return s;
}function g(e, t, n, i, o, s) {
return i && !i[M] && (i = g(i)), o && !o[M] && (o = g(o, s)), r(function (r, s, a, c) {
var l,
u,
d,
h = [],
g = [],
v = s.length,
m = r || f(t || "*", a.nodeType ? [a] : a, []),
y = !e || !r && t ? m : p(m, h, e, a, c),
b = n ? o || (r ? e : v || i) ? [] : s : y;if (n && n(y, b, a, c), i) for (l = p(b, g), i(l, [], a, c), u = l.length; u--;) {
(d = l[u]) && (b[g[u]] = !(y[g[u]] = d));
}if (r) {
if (o || e) {
if (o) {
for (l = [], u = b.length; u--;) {
(d = b[u]) && l.push(y[u] = d);
}o(null, b = [], l, c);
}for (u = b.length; u--;) {
(d = b[u]) && (l = o ? Q(r, d) : h[u]) > -1 && (r[l] = !(s[l] = d));
}
}
} else b = p(b === s ? b.splice(v, b.length) : b), o ? o(null, s, b, c) : U.apply(s, b);
});
}function v(e) {
for (var t, n, r, i = e.length, o = x.relative[e[0].type], s = o || x.relative[" "], a = o ? 1 : 0, c = d(function (e) {
return e === t;
}, s, !0), l = d(function (e) {
return Q(t, e) > -1;
}, s, !0), f = [function (e, n, r) {
var i = !o && (r || n !== j) || ((t = n).nodeType ? c(e, n, r) : l(e, n, r));return t = null, i;
}]; i > a; a++) {
if (n = x.relative[e[a].type]) f = [d(h(f), n)];else {
if (n = x.filter[e[a].type].apply(null, e[a].matches), n[M]) {
for (r = ++a; i > r && !x.relative[e[r].type]; r++) {}return g(a > 1 && h(f), a > 1 && u(e.slice(0, a - 1).concat({ value: " " === e[a - 2].type ? "*" : "" })).replace(se, "$1"), n, r > a && v(e.slice(a, r)), i > r && v(e = e.slice(r)), i > r && u(e));
}f.push(n);
}
}return h(f);
}function m(e, n) {
var i = n.length > 0,
o = e.length > 0,
s = function s(r, _s, a, c, l) {
var u,
d,
h,
f = 0,
g = "0",
v = r && [],
m = [],
y = j,
b = r || o && x.find.TAG("*", l),
w = F += null == y ? 1 : Math.random() || .1,
$ = b.length;for (l && (j = _s !== S && _s); g !== $ && null != (u = b[g]); g++) {
if (o && u) {
for (d = 0; h = e[d++];) {
if (h(u, _s, a)) {
c.push(u);break;
}
}l && (F = w);
}i && ((u = !h && u) && f--, r && v.push(u));
}if (f += g, i && g !== f) {
for (d = 0; h = n[d++];) {
h(v, m, _s, a);
}if (r) {
if (f > 0) for (; g--;) {
v[g] || m[g] || (m[g] = X.call(c));
}m = p(m);
}U.apply(c, m), l && !r && m.length > 0 && f + n.length > 1 && t.uniqueSort(c);
}return l && (F = w, j = y), v;
};return i ? r(s) : s;
}var y,
b,
x,
w,
$,
k,
C,
T,
j,
_,
N,
D,
S,
E,
A,
P,
L,
q,
H,
M = "sizzle" + 1 * new Date(),
O = e.document,
F = 0,
R = 0,
W = n(),
I = n(),
B = n(),
K = function K(e, t) {
return e === t && (N = !0), 0;
},
z = 1 << 31,
Y = {}.hasOwnProperty,
G = [],
X = G.pop,
V = G.push,
U = G.push,
J = G.slice,
Q = function Q(e, t) {
for (var n = 0, r = e.length; r > n; n++) {
if (e[n] === t) return n;
}return -1;
},
Z = "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",
ee = "[\\x20\\t\\r\\n\\f]",
te = "(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",
ne = te.replace("w", "w#"),
re = "\\[" + ee + "*(" + te + ")(?:" + ee + "*([*^$|!~]?=)" + ee + "*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" + ne + "))|)" + ee + "*\\]",
ie = ":(" + te + ")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|" + re + ")*)|.*)\\)|)",
oe = new RegExp(ee + "+", "g"),
se = new RegExp("^" + ee + "+|((?:^|[^\\\\])(?:\\\\.)*)" + ee + "+$", "g"),
ae = new RegExp("^" + ee + "*," + ee + "*"),
ce = new RegExp("^" + ee + "*([>+~]|" + ee + ")" + ee + "*"),
le = new RegExp("=" + ee + "*([^\\]'\"]*?)" + ee + "*\\]", "g"),
ue = new RegExp(ie),
de = new RegExp("^" + ne + "$"),
he = { ID: new RegExp("^#(" + te + ")"), CLASS: new RegExp("^\\.(" + te + ")"), TAG: new RegExp("^(" + te.replace("w", "w*") + ")"), ATTR: new RegExp("^" + re), PSEUDO: new RegExp("^" + ie), CHILD: new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" + ee + "*(even|odd|(([+-]|)(\\d*)n|)" + ee + "*(?:([+-]|)" + ee + "*(\\d+)|))" + ee + "*\\)|)", "i"), bool: new RegExp("^(?:" + Z + ")$", "i"), needsContext: new RegExp("^" + ee + "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" + ee + "*((?:-\\d)?\\d*)" + ee + "*\\)|)(?=[^-]|$)", "i") },
fe = /^(?:input|select|textarea|button)$/i,
pe = /^h\d$/i,
ge = /^[^{]+\{\s*\[native \w/,
ve = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,
me = /[+~]/,
ye = /'|\\/g,
be = new RegExp("\\\\([\\da-f]{1,6}" + ee + "?|(" + ee + ")|.)", "ig"),
xe = function xe(e, t, n) {
var r = "0x" + t - 65536;return r !== r || n ? t : 0 > r ? String.fromCharCode(r + 65536) : String.fromCharCode(r >> 10 | 55296, 1023 & r | 56320);
},
we = function we() {
D();
};try {
U.apply(G = J.call(O.childNodes), O.childNodes), G[O.childNodes.length].nodeType;
} catch (e) {
U = { apply: G.length ? function (e, t) {
V.apply(e, J.call(t));
} : function (e, t) {
for (var n = e.length, r = 0; e[n++] = t[r++];) {}e.length = n - 1;
} };
}b = t.support = {}, $ = t.isXML = function (e) {
var t = e && (e.ownerDocument || e).documentElement;return !!t && "HTML" !== t.nodeName;
}, D = t.setDocument = function (e) {
var t,
n,
r = e ? e.ownerDocument || e : O;return r !== S && 9 === r.nodeType && r.documentElement ? (S = r, E = r.documentElement, n = r.defaultView, n && n !== n.top && (n.addEventListener ? n.addEventListener("unload", we, !1) : n.attachEvent && n.attachEvent("onunload", we)), A = !$(r), b.attributes = i(function (e) {
return e.className = "i", !e.getAttribute("className");
}), b.getElementsByTagName = i(function (e) {
return e.appendChild(r.createComment("")), !e.getElementsByTagName("*").length;
}), b.getElementsByClassName = ge.test(r.getElementsByClassName), b.getById = i(function (e) {
return E.appendChild(e).id = M, !r.getElementsByName || !r.getElementsByName(M).length;
}), b.getById ? (x.find.ID = function (e, t) {
if (void 0 !== t.getElementById && A) {
var n = t.getElementById(e);return n && n.parentNode ? [n] : [];
}
}, x.filter.ID = function (e) {
var t = e.replace(be, xe);return function (e) {
return e.getAttribute("id") === t;
};
}) : (delete x.find.ID, x.filter.ID = function (e) {
var t = e.replace(be, xe);return function (e) {
var n = void 0 !== e.getAttributeNode && e.getAttributeNode("id");return n && n.value === t;
};
}), x.find.TAG = b.getElementsByTagName ? function (e, t) {
return void 0 !== t.getElementsByTagName ? t.getElementsByTagName(e) : b.qsa ? t.querySelectorAll(e) : void 0;
} : function (e, t) {
var n,
r = [],
i = 0,
o = t.getElementsByTagName(e);if ("*" === e) {
for (; n = o[i++];) {
1 === n.nodeType && r.push(n);
}return r;
}return o;
}, x.find.CLASS = b.getElementsByClassName && function (e, t) {
return A ? t.getElementsByClassName(e) : void 0;
}, L = [], P = [], (b.qsa = ge.test(r.querySelectorAll)) && (i(function (e) {
E.appendChild(e).innerHTML = "<a id='" + M + "'></a><select id='" + M + "-\f]' msallowcapture=''><option selected=''></option></select>", e.querySelectorAll("[msallowcapture^='']").length && P.push("[*^$]=" + ee + "*(?:''|\"\")"), e.querySelectorAll("[selected]").length || P.push("\\[" + ee + "*(?:value|" + Z + ")"), e.querySelectorAll("[id~=" + M + "-]").length || P.push("~="), e.querySelectorAll(":checked").length || P.push(":checked"), e.querySelectorAll("a#" + M + "+*").length || P.push(".#.+[+~]");
}), i(function (e) {
var t = r.createElement("input");t.setAttribute("type", "hidden"), e.appendChild(t).setAttribute("name", "D"), e.querySelectorAll("[name=d]").length && P.push("name" + ee + "*[*^$|!~]?="), e.querySelectorAll(":enabled").length || P.push(":enabled", ":disabled"), e.querySelectorAll("*,:x"), P.push(",.*:");
})), (b.matchesSelector = ge.test(q = E.matches || E.webkitMatchesSelector || E.mozMatchesSelector || E.oMatchesSelector || E.msMatchesSelector)) && i(function (e) {
b.disconnectedMatch = q.call(e, "div"), q.call(e, "[s!='']:x"), L.push("!=", ie);
}), P = P.length && new RegExp(P.join("|")), L = L.length && new RegExp(L.join("|")), t = ge.test(E.compareDocumentPosition), H = t || ge.test(E.contains) ? function (e, t) {
var n = 9 === e.nodeType ? e.documentElement : e,
r = t && t.parentNode;return e === r || !(!r || 1 !== r.nodeType || !(n.contains ? n.contains(r) : e.compareDocumentPosition && 16 & e.compareDocumentPosition(r)));
} : function (e, t) {
if (t) for (; t = t.parentNode;) {
if (t === e) return !0;
}return !1;
}, K = t ? function (e, t) {
if (e === t) return N = !0, 0;var n = !e.compareDocumentPosition - !t.compareDocumentPosition;return n ? n : (n = (e.ownerDocument || e) === (t.ownerDocument || t) ? e.compareDocumentPosition(t) : 1, 1 & n || !b.sortDetached && t.compareDocumentPosition(e) === n ? e === r || e.ownerDocument === O && H(O, e) ? -1 : t === r || t.ownerDocument === O && H(O, t) ? 1 : _ ? Q(_, e) - Q(_, t) : 0 : 4 & n ? -1 : 1);
} : function (e, t) {
if (e === t) return N = !0, 0;var n,
i = 0,
o = e.parentNode,
a = t.parentNode,
c = [e],
l = [t];if (!o || !a) return e === r ? -1 : t === r ? 1 : o ? -1 : a ? 1 : _ ? Q(_, e) - Q(_, t) : 0;if (o === a) return s(e, t);for (n = e; n = n.parentNode;) {
c.unshift(n);
}for (n = t; n = n.parentNode;) {
l.unshift(n);
}for (; c[i] === l[i];) {
i++;
}return i ? s(c[i], l[i]) : c[i] === O ? -1 : l[i] === O ? 1 : 0;
}, r) : S;
}, t.matches = function (e, n) {
return t(e, null, null, n);
}, t.matchesSelector = function (e, n) {
if ((e.ownerDocument || e) !== S && D(e), n = n.replace(le, "='$1']"), !(!b.matchesSelector || !A || L && L.test(n) || P && P.test(n))) try {
var r = q.call(e, n);if (r || b.disconnectedMatch || e.document && 11 !== e.document.nodeType) return r;
} catch (e) {}return t(n, S, null, [e]).length > 0;
}, t.contains = function (e, t) {
return (e.ownerDocument || e) !== S && D(e), H(e, t);
}, t.attr = function (e, t) {
(e.ownerDocument || e) !== S && D(e);var n = x.attrHandle[t.toLowerCase()],
r = n && Y.call(x.attrHandle, t.toLowerCase()) ? n(e, t, !A) : void 0;return void 0 !== r ? r : b.attributes || !A ? e.getAttribute(t) : (r = e.getAttributeNode(t)) && r.specified ? r.value : null;
}, t.error = function (e) {
throw new Error("Syntax error, unrecognized expression: " + e);
}, t.uniqueSort = function (e) {
var t,
n = [],
r = 0,
i = 0;if (N = !b.detectDuplicates, _ = !b.sortStable && e.slice(0), e.sort(K), N) {
for (; t = e[i++];) {
t === e[i] && (r = n.push(i));
}for (; r--;) {
e.splice(n[r], 1);
}
}return _ = null, e;
}, w = t.getText = function (e) {
var t,
n = "",
r = 0,
i = e.nodeType;if (i) {
if (1 === i || 9 === i || 11 === i) {
if ("string" == typeof e.textContent) return e.textContent;for (e = e.firstChild; e; e = e.nextSibling) {
n += w(e);
}
} else if (3 === i || 4 === i) return e.nodeValue;
} else for (; t = e[r++];) {
n += w(t);
}return n;
}, x = t.selectors = { cacheLength: 50, createPseudo: r, match: he, attrHandle: {}, find: {}, relative: { ">": { dir: "parentNode", first: !0 }, " ": { dir: "parentNode" }, "+": { dir: "previousSibling", first: !0 }, "~": { dir: "previousSibling" } }, preFilter: { ATTR: function ATTR(e) {
return e[1] = e[1].replace(be, xe), e[3] = (e[3] || e[4] || e[5] || "").replace(be, xe), "~=" === e[2] && (e[3] = " " + e[3] + " "), e.slice(0, 4);
}, CHILD: function CHILD(e) {
return e[1] = e[1].toLowerCase(), "nth" === e[1].slice(0, 3) ? (e[3] || t.error(e[0]), e[4] = +(e[4] ? e[5] + (e[6] || 1) : 2 * ("even" === e[3] || "odd" === e[3])), e[5] = +(e[7] + e[8] || "odd" === e[3])) : e[3] && t.error(e[0]), e;
}, PSEUDO: function PSEUDO(e) {
var t,
n = !e[6] && e[2];return he.CHILD.test(e[0]) ? null : (e[3] ? e[2] = e[4] || e[5] || "" : n && ue.test(n) && (t = k(n, !0)) && (t = n.indexOf(")", n.length - t) - n.length) && (e[0] = e[0].slice(0, t), e[2] = n.slice(0, t)), e.slice(0, 3));
} }, filter: { TAG: function TAG(e) {
var t = e.replace(be, xe).toLowerCase();return "*" === e ? function () {
return !0;
} : function (e) {
return e.nodeName && e.nodeName.toLowerCase() === t;
};
}, CLASS: function CLASS(e) {
var t = W[e + " "];return t || (t = new RegExp("(^|" + ee + ")" + e + "(" + ee + "|$)")) && W(e, function (e) {
return t.test("string" == typeof e.className && e.className || void 0 !== e.getAttribute && e.getAttribute("class") || "");
});
}, ATTR: function ATTR(e, n, r) {
return function (i) {
var o = t.attr(i, e);return null == o ? "!=" === n : !n || (o += "", "=" === n ? o === r : "!=" === n ? o !== r : "^=" === n ? r && 0 === o.indexOf(r) : "*=" === n ? r && o.indexOf(r) > -1 : "$=" === n ? r && o.slice(-r.length) === r : "~=" === n ? (" " + o.replace(oe, " ") + " ").indexOf(r) > -1 : "|=" === n && (o === r || o.slice(0, r.length + 1) === r + "-"));
};
}, CHILD: function CHILD(e, t, n, r, i) {
var o = "nth" !== e.slice(0, 3),
s = "last" !== e.slice(-4),
a = "of-type" === t;return 1 === r && 0 === i ? function (e) {
return !!e.parentNode;
} : function (t, n, c) {
var l,
u,
d,
h,
f,
p,
g = o !== s ? "nextSibling" : "previousSibling",
v = t.parentNode,
m = a && t.nodeName.toLowerCase(),
y = !c && !a;if (v) {
if (o) {
for (; g;) {
for (d = t; d = d[g];) {
if (a ? d.nod