if ("undefined" == typeof jQuery) throw new Error("Bootstrap's JavaScript requires jQuery"); + function(t) { "use strict"; var e = t.fn.jquery.split(" ")[0].split("."); if (e[0] < 2 && e[1] < 9 || 1 == e[0] && 9 == e[1] && e[2] < 1 || e[0] > 3) throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4") }(jQuery), + function(t) { "use strict"; function e() { var t = document.createElement("bootstrap"), e = { WebkitTransition: "webkitTransitionEnd", MozTransition: "transitionend", OTransition: "oTransitionEnd otransitionend", transition: "transitionend" }; for (var o in e) if (void 0 !== t.style[o]) return { end: e[o] }; return !1 } t.fn.emulateTransitionEnd = function(e) { var o = !1, i = this; t(this).one("bsTransitionEnd", function() { o = !0 }); var n = function() { o || t(i).trigger(t.support.transition.end) }; return setTimeout(n, e), this }, t(function() { t.support.transition = e(), t.support.transition && (t.event.special.bsTransitionEnd = { bindType: t.support.transition.end, delegateType: t.support.transition.end, handle: function(e) { if (t(e.target).is(this)) return e.handleObj.handler.apply(this, arguments) } }) }) }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var o = t(this), n = o.data("bs.alert"); n || o.data("bs.alert", n = new i(this)), "string" == typeof e && n[e].call(o) }) } var o = '[data-dismiss="alert"]', i = function(e) { t(e).on("click", o, this.close) }; i.VERSION = "3.3.7", i.TRANSITION_DURATION = 150, i.prototype.close = function(e) { function o() { r.detach().trigger("closed.bs.alert").remove() } var n = t(this), s = n.attr("data-target"); s || (s = n.attr("href"), s = s && s.replace(/.*(?=#[^\s]*$)/, "")); var r = t("#" === s ? [] : s); e && e.preventDefault(), r.length || (r = n.closest(".alert")), r.trigger(e = t.Event("close.bs.alert")), e.isDefaultPrevented() || (r.removeClass("in"), t.support.transition && r.hasClass("fade") ? r.one("bsTransitionEnd", o).emulateTransitionEnd(i.TRANSITION_DURATION) : o()) }; var n = t.fn.alert; t.fn.alert = e, t.fn.alert.Constructor = i, t.fn.alert.noConflict = function() { return t.fn.alert = n, this }, t(document).on("click.bs.alert.data-api", o, i.prototype.close) }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var i = t(this), n = i.data("bs.button"), s = "object" == typeof e && e; n || i.data("bs.button", n = new o(this, s)), "toggle" == e ? n.toggle() : e && n.setState(e) }) } var o = function(e, i) { this.$element = t(e), this.options = t.extend({}, o.DEFAULTS, i), this.isLoading = !1 }; o.VERSION = "3.3.7", o.DEFAULTS = { loadingText: "loading..." }, o.prototype.setState = function(e) { var o = "disabled", i = this.$element, n = i.is("input") ? "val" : "html", s = i.data(); e += "Text", null == s.resetText && i.data("resetText", i[n]()), setTimeout(t.proxy(function() { i[n](null == s[e] ? this.options[e] : s[e]), "loadingText" == e ? (this.isLoading = !0, i.addClass(o).attr(o, o).prop(o, !0)) : this.isLoading && (this.isLoading = !1, i.removeClass(o).removeAttr(o).prop(o, !1)) }, this), 0) }, o.prototype.toggle = function() { var t = !0, e = this.$element.closest('[data-toggle="buttons"]'); if (e.length) { var o = this.$element.find("input"); "radio" == o.prop("type") ? (o.prop("checked") && (t = !1), e.find(".active").removeClass("active"), this.$element.addClass("active")) : "checkbox" == o.prop("type") && (o.prop("checked") !== this.$element.hasClass("active") && (t = !1), this.$element.toggleClass("active")), o.prop("checked", this.$element.hasClass("active")), t && o.trigger("change") } else this.$element.attr("aria-pressed", !this.$element.hasClass("active")), this.$element.toggleClass("active") }; var i = t.fn.button; t.fn.button = e, t.fn.button.Constructor = o, t.fn.button.noConflict = function() { return t.fn.button = i, this }, t(document).on("click.bs.button.data-api", '[data-toggle^="button"]', function(o) { var i = t(o.target).closest(".btn"); e.call(i, "toggle"), t(o.target).is('input[type="radio"], input[type="checkbox"]') || (o.preventDefault(), i.is("input,button") ? i.trigger("focus") : i.find("input:visible,button:visible").first().trigger("focus")) }).on("focus.bs.button.data-api blur.bs.button.data-api", '[data-toggle^="button"]', function(e) { t(e.target).closest(".btn").toggleClass("focus", /^focus(in)?$/.test(e.type)) }) }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var i = t(this), n = i.data("bs.carousel"), s = t.extend({}, o.DEFAULTS, i.data(), "object" == typeof e && e), r = "string" == typeof e ? e : s.slide; n || i.data("bs.carousel", n = new o(this, s)), "number" == typeof e ? n.to(e) : r ? n[r]() : s.interval && n.pause().cycle() }) } var o = function(e, o) { this.$element = t(e), this.$indicators = this.$element.find(".carousel-indicators"), this.options = o, this.paused = null, this.sliding = null, this.interval = null, this.$active = null, this.$items = null, this.options.keyboard && this.$element.on("keydown.bs.carousel", t.proxy(this.keydown, this)), "hover" == this.options.pause && !("ontouchstart" in document.documentElement) && this.$element.on("mouseenter.bs.carousel", t.proxy(this.pause, this)).on("mouseleave.bs.carousel", t.proxy(this.cycle, this)) }; o.VERSION = "3.3.7", o.TRANSITION_DURATION = 600, o.DEFAULTS = { interval: 5e3, pause: "hover", wrap: !0, keyboard: !0 }, o.prototype.keydown = function(t) { if (!/input|textarea/i.test(t.target.tagName)) { switch (t.which) { case 37: this.prev(); break; case 39: this.next(); break; default: return } t.preventDefault() } }, o.prototype.cycle = function(e) { return e || (this.paused = !1), this.interval && clearInterval(this.interval), this.options.interval && !this.paused && (this.interval = setInterval(t.proxy(this.next, this), this.options.interval)), this }, o.prototype.getItemIndex = function(t) { return this.$items = t.parent().children(".item"), this.$items.index(t || this.$active) }, o.prototype.getItemForDirection = function(t, e) { var o = this.getItemIndex(e), i = "prev" == t && 0 === o || "next" == t && o == this.$items.length - 1; if (i && !this.options.wrap) return e; var n = "prev" == t ? -1 : 1, s = (o + n) % this.$items.length; return this.$items.eq(s) }, o.prototype.to = function(t) { var e = this, o = this.getItemIndex(this.$active = this.$element.find(".item.active")); if (!(t > this.$items.length - 1 || t < 0)) return this.sliding ? this.$element.one("slid.bs.carousel", function() { e.to(t) }) : o == t ? this.pause().cycle() : this.slide(t > o ? "next" : "prev", this.$items.eq(t)) }, o.prototype.pause = function(e) { return e || (this.paused = !0), this.$element.find(".next, .prev").length && t.support.transition && (this.$element.trigger(t.support.transition.end), this.cycle(!0)), this.interval = clearInterval(this.interval), this }, o.prototype.next = function() { if (!this.sliding) return this.slide("next") }, o.prototype.prev = function() { if (!this.sliding) return this.slide("prev") }, o.prototype.slide = function(e, i) { var n = this.$element.find(".item.active"), s = i || this.getItemForDirection(e, n), r = this.interval, a = "next" == e ? "left" : "right", l = this; if (s.hasClass("active")) return this.sliding = !1; var h = s[0], d = t.Event("slide.bs.carousel", { relatedTarget: h, direction: a }); if (this.$element.trigger(d), !d.isDefaultPrevented()) { if (this.sliding = !0, r && this.pause(), this.$indicators.length) { this.$indicators.find(".active").removeClass("active"); var c = t(this.$indicators.children()[this.getItemIndex(s)]); c && c.addClass("active") } var p = t.Event("slid.bs.carousel", { relatedTarget: h, direction: a }); return t.support.transition && this.$element.hasClass("slide") ? (s.addClass(e), s[0].offsetWidth, n.addClass(a), s.addClass(a), n.one("bsTransitionEnd", function() { s.removeClass([e, a].join(" ")).addClass("active"), n.removeClass(["active", a].join(" ")), l.sliding = !1, setTimeout(function() { l.$element.trigger(p) }, 0) }).emulateTransitionEnd(o.TRANSITION_DURATION)) : (n.removeClass("active"), s.addClass("active"), this.sliding = !1, this.$element.trigger(p)), r && this.cycle(), this } }; var i = t.fn.carousel; t.fn.carousel = e, t.fn.carousel.Constructor = o, t.fn.carousel.noConflict = function() { return t.fn.carousel = i, this }; var n = function(o) { var i, n = t(this), s = t(n.attr("data-target") || (i = n.attr("href")) && i.replace(/.*(?=#[^\s]+$)/, "")); if (s.hasClass("carousel")) { var r = t.extend({}, s.data(), n.data()), a = n.attr("data-slide-to"); a && (r.interval = !1), e.call(s, r), a && s.data("bs.carousel").to(a), o.preventDefault() } }; t(document).on("click.bs.carousel.data-api", "[data-slide]", n).on("click.bs.carousel.data-api", "[data-slide-to]", n), t(window).on("load", function() { t('[data-ride="carousel"]').each(function() { var o = t(this); e.call(o, o.data()) }) }) }(jQuery), + function(t) { "use strict"; function e(e) { var o, i = e.attr("data-target") || (o = e.attr("href")) && o.replace(/.*(?=#[^\s]+$)/, ""); return t(i) } function o(e) { return this.each(function() { var o = t(this), n = o.data("bs.collapse"), s = t.extend({}, i.DEFAULTS, o.data(), "object" == typeof e && e); !n && s.toggle && /show|hide/.test(e) && (s.toggle = !1), n || o.data("bs.collapse", n = new i(this, s)), "string" == typeof e && n[e]() }) } var i = function(e, o) { this.$element = t(e), this.options = t.extend({}, i.DEFAULTS, o), this.$trigger = t('[data-toggle="collapse"][href="#' + e.id + '"],[data-toggle="collapse"][data-target="#' + e.id + '"]'), this.transitioning = null, this.options.parent ? this.$parent = this.getParent() : this.addAriaAndCollapsedClass(this.$element, this.$trigger), this.options.toggle && this.toggle() }; i.VERSION = "3.3.7", i.TRANSITION_DURATION = 350, i.DEFAULTS = { toggle: !0 }, i.prototype.dimension = function() { var t = this.$element.hasClass("width"); return t ? "width" : "height" }, i.prototype.show = function() { if (!this.transitioning && !this.$element.hasClass("in")) { var e, n = this.$parent && this.$parent.children(".panel").children(".in, .collapsing"); if (!(n && n.length && (e = n.data("bs.collapse"), e && e.transitioning))) { var s = t.Event("show.bs.collapse"); if (this.$element.trigger(s), !s.isDefaultPrevented()) { n && n.length && (o.call(n, "hide"), e || n.data("bs.collapse", null)); var r = this.dimension(); this.$element.removeClass("collapse").addClass("collapsing")[r](0).attr("aria-expanded", !0), this.$trigger.removeClass("collapsed").attr("aria-expanded", !0), this.transitioning = 1; var a = function() { this.$element.removeClass("collapsing").addClass("collapse in")[r](""), this.transitioning = 0, this.$element.trigger("shown.bs.collapse") }; if (!t.support.transition) return a.call(this); var l = t.camelCase(["scroll", r].join("-")); this.$element.one("bsTransitionEnd", t.proxy(a, this)).emulateTransitionEnd(i.TRANSITION_DURATION)[r](this.$element[0][l]) } } } }, i.prototype.hide = function() { if (!this.transitioning && this.$element.hasClass("in")) { var e = t.Event("hide.bs.collapse"); if (this.$element.trigger(e), !e.isDefaultPrevented()) { var o = this.dimension(); this.$element[o](this.$element[o]())[0].offsetHeight, this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded", !1), this.$trigger.addClass("collapsed").attr("aria-expanded", !1), this.transitioning = 1; var n = function() { this.transitioning = 0, this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse") }; return t.support.transition ? void this.$element[o](0).one("bsTransitionEnd", t.proxy(n, this)).emulateTransitionEnd(i.TRANSITION_DURATION) : n.call(this) } } }, i.prototype.toggle = function() { this[this.$element.hasClass("in") ? "hide" : "show"]() }, i.prototype.getParent = function() { return t(this.options.parent).find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]').each(t.proxy(function(o, i) { var n = t(i); this.addAriaAndCollapsedClass(e(n), n) }, this)).end() }, i.prototype.addAriaAndCollapsedClass = function(t, e) { var o = t.hasClass("in"); t.attr("aria-expanded", o), e.toggleClass("collapsed", !o).attr("aria-expanded", o) }; var n = t.fn.collapse; t.fn.collapse = o, t.fn.collapse.Constructor = i, t.fn.collapse.noConflict = function() { return t.fn.collapse = n, this }, t(document).on("click.bs.collapse.data-api", '[data-toggle="collapse"]', function(i) { var n = t(this); n.attr("data-target") || i.preventDefault(); var s = e(n), r = s.data("bs.collapse"), a = r ? "toggle" : n.data(); o.call(s, a) }) }(jQuery), + function(t) { "use strict"; function e(e) { var o = e.attr("data-target"); o || (o = e.attr("href"), o = o && /#[A-Za-z]/.test(o) && o.replace(/.*(?=#[^\s]*$)/, "")); var i = o && t(o); return i && i.length ? i : e.parent() } function o(o) { o && 3 === o.which || (t(n).remove(), t(s).each(function() { var i = t(this), n = e(i), s = { relatedTarget: this }; n.hasClass("open") && (o && "click" == o.type && /input|textarea/i.test(o.target.tagName) && t.contains(n[0], o.target) || (n.trigger(o = t.Event("hide.bs.dropdown", s)), o.isDefaultPrevented() || (i.attr("aria-expanded", "false"), n.removeClass("open").trigger(t.Event("hidden.bs.dropdown", s))))) })) } function i(e) { return this.each(function() { var o = t(this), i = o.data("bs.dropdown"); i || o.data("bs.dropdown", i = new r(this)), "string" == typeof e && i[e].call(o) }) } var n = ".dropdown-backdrop", s = '[data-toggle="dropdown"]', r = function(e) { t(e).on("click.bs.dropdown", this.toggle) }; r.VERSION = "3.3.7", r.prototype.toggle = function(i) { var n = t(this); if (!n.is(".disabled, :disabled")) { var s = e(n), r = s.hasClass("open"); if (o(), !r) { "ontouchstart" in document.documentElement && !s.closest(".navbar-nav").length && t(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(t(this)).on("click", o); var a = { relatedTarget: this }; if (s.trigger(i = t.Event("show.bs.dropdown", a)), i.isDefaultPrevented()) return; n.trigger("focus").attr("aria-expanded", "true"), s.toggleClass("open").trigger(t.Event("shown.bs.dropdown", a)) } return !1 } }, r.prototype.keydown = function(o) { if (/(38|40|27|32)/.test(o.which) && !/input|textarea/i.test(o.target.tagName)) { var i = t(this); if (o.preventDefault(), o.stopPropagation(), !i.is(".disabled, :disabled")) { var n = e(i), r = n.hasClass("open"); if (!r && 27 != o.which || r && 27 == o.which) return 27 == o.which && n.find(s).trigger("focus"), i.trigger("click"); var a = " li:not(.disabled):visible a", l = n.find(".dropdown-menu" + a); if (l.length) { var h = l.index(o.target); 38 == o.which && h > 0 && h--, 40 == o.which && h < l.length - 1 && h++, ~h || (h = 0), l.eq(h).trigger("focus") } } } }; var a = t.fn.dropdown; t.fn.dropdown = i, t.fn.dropdown.Constructor = r, t.fn.dropdown.noConflict = function() { return t.fn.dropdown = a, this }, t(document).on("click.bs.dropdown.data-api", o).on("click.bs.dropdown.data-api", ".dropdown form", function(t) { t.stopPropagation() }).on("click.bs.dropdown.data-api", s, r.prototype.toggle).on("keydown.bs.dropdown.data-api", s, r.prototype.keydown).on("keydown.bs.dropdown.data-api", ".dropdown-menu", r.prototype.keydown) }(jQuery), + function(t) { "use strict"; function e(e, i) { return this.each(function() { var n = t(this), s = n.data("bs.modal"), r = t.extend({}, o.DEFAULTS, n.data(), "object" == typeof e && e); s || n.data("bs.modal", s = new o(this, r)), "string" == typeof e ? s[e](i) : r.show && s.show(i) }) } var o = function(e, o) { this.options = o, this.$body = t(document.body), this.$element = t(e), this.$dialog = this.$element.find(".modal-dialog"), this.$backdrop = null, this.isShown = null, this.originalBodyPad = null, this.scrollbarWidth = 0, this.ignoreBackdropClick = !1, this.options.remote && this.$element.find(".modal-content").load(this.options.remote, t.proxy(function() { this.$element.trigger("loaded.bs.modal") }, this)) }; o.VERSION = "3.3.7", o.TRANSITION_DURATION = 300, o.BACKDROP_TRANSITION_DURATION = 150, o.DEFAULTS = { backdrop: !0, keyboard: !0, show: !0 }, o.prototype.toggle = function(t) { return this.isShown ? this.hide() : this.show(t) }, o.prototype.show = function(e) { var i = this, n = t.Event("show.bs.modal", { relatedTarget: e }); this.$element.trigger(n), this.isShown || n.isDefaultPrevented() || (this.isShown = !0, this.checkScrollbar(), this.setScrollbar(), this.$body.addClass("modal-open"), this.escape(), this.resize(), this.$element.on("click.dismiss.bs.modal", '[data-dismiss="modal"]', t.proxy(this.hide, this)), this.$dialog.on("mousedown.dismiss.bs.modal", function() { i.$element.one("mouseup.dismiss.bs.modal", function(e) { t(e.target).is(i.$element) && (i.ignoreBackdropClick = !0) }) }), this.backdrop(function() { var n = t.support.transition && i.$element.hasClass("fade"); i.$element.parent().length || i.$element.appendTo(i.$body), i.$element.show().scrollTop(0), i.adjustDialog(), n && i.$element[0].offsetWidth, i.$element.addClass("in"), i.enforceFocus(); var s = t.Event("shown.bs.modal", { relatedTarget: e }); n ? i.$dialog.one("bsTransitionEnd", function() { i.$element.trigger("focus").trigger(s) }).emulateTransitionEnd(o.TRANSITION_DURATION) : i.$element.trigger("focus").trigger(s) })) }, o.prototype.hide = function(e) { e && e.preventDefault(), e = t.Event("hide.bs.modal"), this.$element.trigger(e), this.isShown && !e.isDefaultPrevented() && (this.isShown = !1, this.escape(), this.resize(), t(document).off("focusin.bs.modal"), this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"), this.$dialog.off("mousedown.dismiss.bs.modal"), t.support.transition && this.$element.hasClass("fade") ? this.$element.one("bsTransitionEnd", t.proxy(this.hideModal, this)).emulateTransitionEnd(o.TRANSITION_DURATION) : this.hideModal()) }, o.prototype.enforceFocus = function() { t(document).off("focusin.bs.modal").on("focusin.bs.modal", t.proxy(function(t) { document === t.target || this.$element[0] === t.target || this.$element.has(t.target).length || this.$element.trigger("focus") }, this)) }, o.prototype.escape = function() { this.isShown && this.options.keyboard ? this.$element.on("keydown.dismiss.bs.modal", t.proxy(function(t) { 27 == t.which && this.hide() }, this)) : this.isShown || this.$element.off("keydown.dismiss.bs.modal") }, o.prototype.resize = function() { this.isShown ? t(window).on("resize.bs.modal", t.proxy(this.handleUpdate, this)) : t(window).off("resize.bs.modal") }, o.prototype.hideModal = function() { var t = this; this.$element.hide(), this.backdrop(function() { t.$body.removeClass("modal-open"), t.resetAdjustments(), t.resetScrollbar(), t.$element.trigger("hidden.bs.modal") }) }, o.prototype.removeBackdrop = function() { this.$backdrop && this.$backdrop.remove(), this.$backdrop = null }, o.prototype.backdrop = function(e) { var i = this, n = this.$element.hasClass("fade") ? "fade" : ""; if (this.isShown && this.options.backdrop) { var s = t.support.transition && n; if (this.$backdrop = t(document.createElement("div")).addClass("modal-backdrop " + n).appendTo(this.$body), this.$element.on("click.dismiss.bs.modal", t.proxy(function(t) { return this.ignoreBackdropClick ? void(this.ignoreBackdropClick = !1) : void(t.target === t.currentTarget && ("static" == this.options.backdrop ? this.$element[0].focus() : this.hide())) }, this)), s && this.$backdrop[0].offsetWidth, this.$backdrop.addClass("in"), !e) return; s ? this.$backdrop.one("bsTransitionEnd", e).emulateTransitionEnd(o.BACKDROP_TRANSITION_DURATION) : e() } else if (!this.isShown && this.$backdrop) { this.$backdrop.removeClass("in"); var r = function() { i.removeBackdrop(), e && e() }; t.support.transition && this.$element.hasClass("fade") ? this.$backdrop.one("bsTransitionEnd", r).emulateTransitionEnd(o.BACKDROP_TRANSITION_DURATION) : r() } else e && e() }, o.prototype.handleUpdate = function() { this.adjustDialog() }, o.prototype.adjustDialog = function() { var t = this.$element[0].scrollHeight > document.documentElement.clientHeight; this.$element.css({ paddingLeft: !this.bodyIsOverflowing && t ? this.scrollbarWidth : "", paddingRight: this.bodyIsOverflowing && !t ? this.scrollbarWidth : "" }) }, o.prototype.resetAdjustments = function() { this.$element.css({ paddingLeft: "", paddingRight: "" }) }, o.prototype.checkScrollbar = function() { var t = window.innerWidth; if (!t) { var e = document.documentElement.getBoundingClientRect(); t = e.right - Math.abs(e.left) } this.bodyIsOverflowing = document.body.clientWidth < t, this.scrollbarWidth = this.measureScrollbar() }, o.prototype.setScrollbar = function() { var t = parseInt(this.$body.css("padding-right") || 0, 10); this.originalBodyPad = document.body.style.paddingRight || "", this.bodyIsOverflowing && this.$body.css("padding-right", t + this.scrollbarWidth) }, o.prototype.resetScrollbar = function() { this.$body.css("padding-right", this.originalBodyPad) }, o.prototype.measureScrollbar = function() { var t = document.createElement("div"); t.className = "modal-scrollbar-measure", this.$body.append(t); var e = t.offsetWidth - t.clientWidth; return this.$body[0].removeChild(t), e }; var i = t.fn.modal; t.fn.modal = e, t.fn.modal.Constructor = o, t.fn.modal.noConflict = function() { return t.fn.modal = i, this }, t(document).on("click.bs.modal.data-api", '[data-toggle="modal"]', function(o) { var i = t(this), n = i.attr("href"), s = t(i.attr("data-target") || n && n.replace(/.*(?=#[^\s]+$)/, "")), r = s.data("bs.modal") ? "toggle" : t.extend({ remote: !/#/.test(n) && n }, s.data(), i.data()); i.is("a") && o.preventDefault(), s.one("show.bs.modal", function(t) { t.isDefaultPrevented() || s.one("hidden.bs.modal", function() { i.is(":visible") && i.trigger("focus") }) }), e.call(s, r, this) }) }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var i = t(this), n = i.data("bs.tooltip"), s = "object" == typeof e && e; !n && /destroy|hide/.test(e) || (n || i.data("bs.tooltip", n = new o(this, s)), "string" == typeof e && n[e]()) }) } var o = function(t, e) { this.type = null, this.options = null, this.enabled = null, this.timeout = null, this.hoverState = null, this.$element = null, this.inState = null, this.init("tooltip", t, e) }; o.VERSION = "3.3.7", o.TRANSITION_DURATION = 150, o.DEFAULTS = { animation: !0, placement: "top", selector: !1, template: '', trigger: "hover focus", title: "", delay: 0, html: !1, container: !1, viewport: { selector: "body", padding: 0 } }, o.prototype.init = function(e, o, i) { if (this.enabled = !0, this.type = e, this.$element = t(o), this.options = this.getOptions(i), this.$viewport = this.options.viewport && t(t.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : this.options.viewport.selector || this.options.viewport), this.inState = { click: !1, hover: !1, focus: !1 }, this.$element[0] instanceof document.constructor && !this.options.selector) throw new Error("`selector` option must be specified when initializing " + this.type + " on the window.document object!"); for (var n = this.options.trigger.split(" "), s = n.length; s--;) { var r = n[s]; if ("click" == r) this.$element.on("click." + this.type, this.options.selector, t.proxy(this.toggle, this)); else if ("manual" != r) { var a = "hover" == r ? "mouseenter" : "focusin", l = "hover" == r ? "mouseleave" : "focusout"; this.$element.on(a + "." + this.type, this.options.selector, t.proxy(this.enter, this)), this.$element.on(l + "." + this.type, this.options.selector, t.proxy(this.leave, this)) } } this.options.selector ? this._options = t.extend({}, this.options, { trigger: "manual", selector: "" }) : this.fixTitle() }, o.prototype.getDefaults = function() { return o.DEFAULTS }, o.prototype.getOptions = function(e) { return e = t.extend({}, this.getDefaults(), this.$element.data(), e), e.delay && "number" == typeof e.delay && (e.delay = { show: e.delay, hide: e.delay }), e }, o.prototype.getDelegateOptions = function() { var e = {}, o = this.getDefaults(); return this._options && t.each(this._options, function(t, i) { o[t] != i && (e[t] = i) }), e }, o.prototype.enter = function(e) { var o = e instanceof this.constructor ? e : t(e.currentTarget).data("bs." + this.type); return o || (o = new this.constructor(e.currentTarget, this.getDelegateOptions()), t(e.currentTarget).data("bs." + this.type, o)), e instanceof t.Event && (o.inState["focusin" == e.type ? "focus" : "hover"] = !0), o.tip().hasClass("in") || "in" == o.hoverState ? void(o.hoverState = "in") : (clearTimeout(o.timeout), o.hoverState = "in", o.options.delay && o.options.delay.show ? void(o.timeout = setTimeout(function() { "in" == o.hoverState && o.show() }, o.options.delay.show)) : o.show()) }, o.prototype.isInStateTrue = function() { for (var t in this.inState) if (this.inState[t]) return !0; return !1 }, o.prototype.leave = function(e) { var o = e instanceof this.constructor ? e : t(e.currentTarget).data("bs." + this.type); if (o || (o = new this.constructor(e.currentTarget, this.getDelegateOptions()), t(e.currentTarget).data("bs." + this.type, o)), e instanceof t.Event && (o.inState["focusout" == e.type ? "focus" : "hover"] = !1), !o.isInStateTrue()) return clearTimeout(o.timeout), o.hoverState = "out", o.options.delay && o.options.delay.hide ? void(o.timeout = setTimeout(function() { "out" == o.hoverState && o.hide() }, o.options.delay.hide)) : o.hide() }, o.prototype.show = function() { var e = t.Event("show.bs." + this.type); if (this.hasContent() && this.enabled) { this.$element.trigger(e); var i = t.contains(this.$element[0].ownerDocument.documentElement, this.$element[0]); if (e.isDefaultPrevented() || !i) return; var n = this, s = this.tip(), r = this.getUID(this.type); this.setContent(), s.attr("id", r), this.$element.attr("aria-describedby", r), this.options.animation && s.addClass("fade"); var a = "function" == typeof this.options.placement ? this.options.placement.call(this, s[0], this.$element[0]) : this.options.placement, l = /\s?auto?\s?/i, h = l.test(a); h && (a = a.replace(l, "") || "top"), s.detach().css({ top: 0, left: 0, display: "block" }).addClass(a).data("bs." + this.type, this), this.options.container ? s.appendTo(this.options.container) : s.insertAfter(this.$element), this.$element.trigger("inserted.bs." + this.type); var d = this.getPosition(), c = s[0].offsetWidth, p = s[0].offsetHeight; if (h) { var u = a, f = this.getPosition(this.$viewport); a = "bottom" == a && d.bottom + p > f.bottom ? "top" : "top" == a && d.top - p < f.top ? "bottom" : "right" == a && d.right + c > f.width ? "left" : "left" == a && d.left - c < f.left ? "right" : a, s.removeClass(u).addClass(a) } var m = this.getCalculatedOffset(a, d, c, p); this.applyPlacement(m, a); var g = function() { var t = n.hoverState; n.$element.trigger("shown.bs." + n.type), n.hoverState = null, "out" == t && n.leave(n) }; t.support.transition && this.$tip.hasClass("fade") ? s.one("bsTransitionEnd", g).emulateTransitionEnd(o.TRANSITION_DURATION) : g() } }, o.prototype.applyPlacement = function(e, o) { var i = this.tip(), n = i[0].offsetWidth, s = i[0].offsetHeight, r = parseInt(i.css("margin-top"), 10), a = parseInt(i.css("margin-left"), 10); isNaN(r) && (r = 0), isNaN(a) && (a = 0), e.top += r, e.left += a, t.offset.setOffset(i[0], t.extend({ using: function(t) { i.css({ top: Math.round(t.top), left: Math.round(t.left) }) } }, e), 0), i.addClass("in"); var l = i[0].offsetWidth, h = i[0].offsetHeight; "top" == o && h != s && (e.top = e.top + s - h); var d = this.getViewportAdjustedDelta(o, e, l, h); d.left ? e.left += d.left : e.top += d.top; var c = /top|bottom/.test(o), p = c ? 2 * d.left - n + l : 2 * d.top - s + h, u = c ? "offsetWidth" : "offsetHeight"; i.offset(e), this.replaceArrow(p, i[0][u], c) }, o.prototype.replaceArrow = function(t, e, o) { this.arrow().css(o ? "left" : "top", 50 * (1 - t / e) + "%").css(o ? "top" : "left", "") }, o.prototype.setContent = function() { var t = this.tip(), e = this.getTitle(); t.find(".tooltip-inner")[this.options.html ? "html" : "text"](e), t.removeClass("fade in top bottom left right") }, o.prototype.hide = function(e) { function i() { "in" != n.hoverState && s.detach(), n.$element && n.$element.removeAttr("aria-describedby").trigger("hidden.bs." + n.type), e && e() } var n = this, s = t(this.$tip), r = t.Event("hide.bs." + this.type); if (this.$element.trigger(r), !r.isDefaultPrevented()) return s.removeClass("in"), t.support.transition && s.hasClass("fade") ? s.one("bsTransitionEnd", i).emulateTransitionEnd(o.TRANSITION_DURATION) : i(), this.hoverState = null, this }, o.prototype.fixTitle = function() { var t = this.$element; (t.attr("title") || "string" != typeof t.attr("data-original-title")) && t.attr("data-original-title", t.attr("title") || "").attr("title", "") }, o.prototype.hasContent = function() { return this.getTitle() }, o.prototype.getPosition = function(e) { e = e || this.$element; var o = e[0], i = "BODY" == o.tagName, n = o.getBoundingClientRect(); null == n.width && (n = t.extend({}, n, { width: n.right - n.left, height: n.bottom - n.top })); var s = window.SVGElement && o instanceof window.SVGElement, r = i ? { top: 0, left: 0 } : s ? null : e.offset(), a = { scroll: i ? document.documentElement.scrollTop || document.body.scrollTop : e.scrollTop() }, l = i ? { width: t(window).width(), height: t(window).height() } : null; return t.extend({}, n, a, l, r) }, o.prototype.getCalculatedOffset = function(t, e, o, i) { return "bottom" == t ? { top: e.top + e.height, left: e.left + e.width / 2 - o / 2 } : "top" == t ? { top: e.top - i, left: e.left + e.width / 2 - o / 2 } : "left" == t ? { top: e.top + e.height / 2 - i / 2, left: e.left - o } : { top: e.top + e.height / 2 - i / 2, left: e.left + e.width } }, o.prototype.getViewportAdjustedDelta = function(t, e, o, i) { var n = { top: 0, left: 0 }; if (!this.$viewport) return n; var s = this.options.viewport && this.options.viewport.padding || 0, r = this.getPosition(this.$viewport); if (/right|left/.test(t)) { var a = e.top - s - r.scroll, l = e.top + s - r.scroll + i; a < r.top ? n.top = r.top - a : l > r.top + r.height && (n.top = r.top + r.height - l) } else { var h = e.left - s, d = e.left + s + o; h < r.left ? n.left = r.left - h : d > r.right && (n.left = r.left + r.width - d) } return n }, o.prototype.getTitle = function() { var t, e = this.$element, o = this.options; return t = e.attr("data-original-title") || ("function" == typeof o.title ? o.title.call(e[0]) : o.title) }, o.prototype.getUID = function(t) { do t += ~~(1e6 * Math.random()); while (document.getElementById(t)); return t }, o.prototype.tip = function() { if (!this.$tip && (this.$tip = t(this.options.template), 1 != this.$tip.length)) throw new Error(this.type + " `template` option must consist of exactly 1 top-level element!"); return this.$tip }, o.prototype.arrow = function() { return this.$arrow = this.$arrow || this.tip().find(".tooltip-arrow") }, o.prototype.enable = function() { this.enabled = !0 }, o.prototype.disable = function() { this.enabled = !1 }, o.prototype.toggleEnabled = function() { this.enabled = !this.enabled }, o.prototype.toggle = function(e) { var o = this; e && (o = t(e.currentTarget).data("bs." + this.type), o || (o = new this.constructor(e.currentTarget, this.getDelegateOptions()), t(e.currentTarget).data("bs." + this.type, o))), e ? (o.inState.click = !o.inState.click, o.isInStateTrue() ? o.enter(o) : o.leave(o)) : o.tip().hasClass("in") ? o.leave(o) : o.enter(o) }, o.prototype.destroy = function() { var t = this; clearTimeout(this.timeout), this.hide(function() { t.$element.off("." + t.type).removeData("bs." + t.type), t.$tip && t.$tip.detach(), t.$tip = null, t.$arrow = null, t.$viewport = null, t.$element = null }) }; var i = t.fn.tooltip; t.fn.tooltip = e, t.fn.tooltip.Constructor = o, t.fn.tooltip.noConflict = function() { return t.fn.tooltip = i, this } }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var i = t(this), n = i.data("bs.popover"), s = "object" == typeof e && e; !n && /destroy|hide/.test(e) || (n || i.data("bs.popover", n = new o(this, s)), "string" == typeof e && n[e]()) }) } var o = function(t, e) { this.init("popover", t, e) }; if (!t.fn.tooltip) throw new Error("Popover requires tooltip.js"); o.VERSION = "3.3.7", o.DEFAULTS = t.extend({}, t.fn.tooltip.Constructor.DEFAULTS, { placement: "right", trigger: "click", content: "", template: '' }), o.prototype = t.extend({}, t.fn.tooltip.Constructor.prototype), o.prototype.constructor = o, o.prototype.getDefaults = function() { return o.DEFAULTS }, o.prototype.setContent = function() { var t = this.tip(), e = this.getTitle(), o = this.getContent(); t.find(".popover-title")[this.options.html ? "html" : "text"](e), t.find(".popover-content").children().detach().end()[this.options.html ? "string" == typeof o ? "html" : "append" : "text"](o), t.removeClass("fade top bottom left right in"), t.find(".popover-title").html() || t.find(".popover-title").hide() }, o.prototype.hasContent = function() { return this.getTitle() || this.getContent() }, o.prototype.getContent = function() { var t = this.$element, e = this.options; return t.attr("data-content") || ("function" == typeof e.content ? e.content.call(t[0]) : e.content) }, o.prototype.arrow = function() { return this.$arrow = this.$arrow || this.tip().find(".arrow") }; var i = t.fn.popover; t.fn.popover = e, t.fn.popover.Constructor = o, t.fn.popover.noConflict = function() { return t.fn.popover = i, this } }(jQuery), + function(t) { "use strict"; function e(o, i) { this.$body = t(document.body), this.$scrollElement = t(t(o).is(document.body) ? window : o), this.options = t.extend({}, e.DEFAULTS, i), this.selector = (this.options.target || "") + " .nav li > a", this.offsets = [], this.targets = [], this.activeTarget = null, this.scrollHeight = 0, this.$scrollElement.on("scroll.bs.scrollspy", t.proxy(this.process, this)), this.refresh(), this.process() } function o(o) { return this.each(function() { var i = t(this), n = i.data("bs.scrollspy"), s = "object" == typeof o && o; n || i.data("bs.scrollspy", n = new e(this, s)), "string" == typeof o && n[o]() }) } e.VERSION = "3.3.7", e.DEFAULTS = { offset: 10 }, e.prototype.getScrollHeight = function() { return this.$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight) }, e.prototype.refresh = function() { var e = this, o = "offset", i = 0; this.offsets = [], this.targets = [], this.scrollHeight = this.getScrollHeight(), t.isWindow(this.$scrollElement[0]) || (o = "position", i = this.$scrollElement.scrollTop()), this.$body.find(this.selector).map(function() { var e = t(this), n = e.data("target") || e.attr("href"), s = /^#./.test(n) && t(n); return s && s.length && s.is(":visible") && [ [s[o]().top + i, n] ] || null }).sort(function(t, e) { return t[0] - e[0] }).each(function() { e.offsets.push(this[0]), e.targets.push(this[1]) }) }, e.prototype.process = function() { var t, e = this.$scrollElement.scrollTop() + this.options.offset, o = this.getScrollHeight(), i = this.options.offset + o - this.$scrollElement.height(), n = this.offsets, s = this.targets, r = this.activeTarget; if (this.scrollHeight != o && this.refresh(), e >= i) return r != (t = s[s.length - 1]) && this.activate(t); if (r && e < n[0]) return this.activeTarget = null, this.clear(); for (t = n.length; t--;) r != s[t] && e >= n[t] && (void 0 === n[t + 1] || e < n[t + 1]) && this.activate(s[t]) }, e.prototype.activate = function(e) { this.activeTarget = e, this.clear(); var o = this.selector + '[data-target="' + e + '"],' + this.selector + '[href="' + e + '"]', i = t(o).parents("li").addClass("active"); i.parent(".dropdown-menu").length && (i = i.closest("li.dropdown").addClass("active")), i.trigger("activate.bs.scrollspy") }, e.prototype.clear = function() { t(this.selector).parentsUntil(this.options.target, ".active").removeClass("active") }; var i = t.fn.scrollspy; t.fn.scrollspy = o, t.fn.scrollspy.Constructor = e, t.fn.scrollspy.noConflict = function() { return t.fn.scrollspy = i, this }, t(window).on("load.bs.scrollspy.data-api", function() { t('[data-spy="scroll"]').each(function() { var e = t(this); o.call(e, e.data()) }) }) }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var i = t(this), n = i.data("bs.tab"); n || i.data("bs.tab", n = new o(this)), "string" == typeof e && n[e]() }) } var o = function(e) { this.element = t(e) }; o.VERSION = "3.3.7", o.TRANSITION_DURATION = 150, o.prototype.show = function() { var e = this.element, o = e.closest("ul:not(.dropdown-menu)"), i = e.data("target"); if (i || (i = e.attr("href"), i = i && i.replace(/.*(?=#[^\s]*$)/, "")), !e.parent("li").hasClass("active")) { var n = o.find(".active:last a"), s = t.Event("hide.bs.tab", { relatedTarget: e[0] }), r = t.Event("show.bs.tab", { relatedTarget: n[0] }); if (n.trigger(s), e.trigger(r), !r.isDefaultPrevented() && !s.isDefaultPrevented()) { var a = t(i); this.activate(e.closest("li"), o), this.activate(a, a.parent(), function() { n.trigger({ type: "hidden.bs.tab", relatedTarget: e[0] }), e.trigger({ type: "shown.bs.tab", relatedTarget: n[0] }) }) } } }, o.prototype.activate = function(e, i, n) { function s() { r.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded", !1), e.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded", !0), a ? (e[0].offsetWidth, e.addClass("in")) : e.removeClass("fade"), e.parent(".dropdown-menu").length && e.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded", !0), n && n() } var r = i.find("> .active"), a = n && t.support.transition && (r.length && r.hasClass("fade") || !!i.find("> .fade").length); r.length && a ? r.one("bsTransitionEnd", s).emulateTransitionEnd(o.TRANSITION_DURATION) : s(), r.removeClass("in") }; var i = t.fn.tab; t.fn.tab = e, t.fn.tab.Constructor = o, t.fn.tab.noConflict = function() { return t.fn.tab = i, this }; var n = function(o) { o.preventDefault(), e.call(t(this), "show") }; t(document).on("click.bs.tab.data-api", '[data-toggle="tab"]', n).on("click.bs.tab.data-api", '[data-toggle="pill"]', n) }(jQuery), + function(t) { "use strict"; function e(e) { return this.each(function() { var i = t(this), n = i.data("bs.affix"), s = "object" == typeof e && e; n || i.data("bs.affix", n = new o(this, s)), "string" == typeof e && n[e]() }) } var o = function(e, i) { this.options = t.extend({}, o.DEFAULTS, i), this.$target = t(this.options.target).on("scroll.bs.affix.data-api", t.proxy(this.checkPosition, this)).on("click.bs.affix.data-api", t.proxy(this.checkPositionWithEventLoop, this)), this.$element = t(e), this.affixed = null, this.unpin = null, this.pinnedOffset = null, this.checkPosition() }; o.VERSION = "3.3.7", o.RESET = "affix affix-top affix-bottom", o.DEFAULTS = { offset: 0, target: window }, o.prototype.getState = function(t, e, o, i) { var n = this.$target.scrollTop(), s = this.$element.offset(), r = this.$target.height(); if (null != o && "top" == this.affixed) return n < o && "top"; if ("bottom" == this.affixed) return null != o ? !(n + this.unpin <= s.top) && "bottom" : !(n + r <= t - i) && "bottom"; var a = null == this.affixed, l = a ? n : s.top, h = a ? r : e; return null != o && n <= o ? "top" : null != i && l + h >= t - i && "bottom" }, o.prototype.getPinnedOffset = function() { if (this.pinnedOffset) return this.pinnedOffset; this.$element.removeClass(o.RESET).addClass("affix"); var t = this.$target.scrollTop(), e = this.$element.offset(); return this.pinnedOffset = e.top - t }, o.prototype.checkPositionWithEventLoop = function() { setTimeout(t.proxy(this.checkPosition, this), 1) }, o.prototype.checkPosition = function() { if (this.$element.is(":visible")) { var e = this.$element.height(), i = this.options.offset, n = i.top, s = i.bottom, r = Math.max(t(document).height(), t(document.body).height()); "object" != typeof i && (s = n = i), "function" == typeof n && (n = i.top(this.$element)), "function" == typeof s && (s = i.bottom(this.$element)); var a = this.getState(r, e, n, s); if (this.affixed != a) { null != this.unpin && this.$element.css("top", ""); var l = "affix" + (a ? "-" + a : ""), h = t.Event(l + ".bs.affix"); if (this.$element.trigger(h), h.isDefaultPrevented()) return; this.affixed = a, this.unpin = "bottom" == a ? this.getPinnedOffset() : null, this.$element.removeClass(o.RESET).addClass(l).trigger(l.replace("affix", "affixed") + ".bs.affix") } "bottom" == a && this.$element.offset({ top: r - e - s }) } }; var i = t.fn.affix; t.fn.affix = e, t.fn.affix.Constructor = o, t.fn.affix.noConflict = function() { return t.fn.affix = i, this }, t(window).on("load", function() { t('[data-spy="affix"]').each(function() { var o = t(this), i = o.data(); i.offset = i.offset || {}, null != i.offsetBottom && (i.offset.bottom = i.offsetBottom), null != i.offsetTop && (i.offset.top = i.offsetTop), e.call(o, i) }) }) }(jQuery), function(t, e) { "object" == typeof exports ? module.exports = e() : "function" == typeof define && define.amd ? define(["jquery", "googlemaps!"], e) : t.GMaps = e() }(this, function() { var t = function(t, e) { var o; if (t === e) return t; for (o in e) void 0 !== e[o] && (t[o] = e[o]); return t }, o = function(t, e) { var o, i = Array.prototype.slice.call(arguments, 2), n = [], s = t.length; if (Array.prototype.map && t.map === Array.prototype.map) n = Array.prototype.map.call(t, function(t) { var o = i.slice(0); return o.splice(0, 0, t), e.apply(this, o) }); else for (o = 0; o < s; o++) callback_params = i, callback_params.splice(0, 0, t[o]), n.push(e.apply(this, callback_params)); return n }, i = function(t) { var e, o = []; for (e = 0; e < t.length; e++) o = o.concat(t[e]); return o }, n = function(t, e) { var o = t[0], i = t[1]; return e && (o = t[1], i = t[0]), new google.maps.LatLng(o, i) }, s = function(t, e) { var o; for (o = 0; o < t.length; o++) t[o] instanceof google.maps.LatLng || (t[o].length > 0 && "object" == typeof t[o][0] ? t[o] = s(t[o], e) : t[o] = n(t[o], e)); return t }, r = function(t, e) { var o, i = t.replace(".", ""); return o = "jQuery" in this && e ? $("." + i, e)[0] : document.getElementsByClassName(i)[0] }, a = function(t, e) { var o, t = t.replace("#", ""); return o = "jQuery" in window && e ? $("#" + t, e)[0] : document.getElementById(t) }, l = function(t) { var e = 0, o = 0; if (t.offsetParent) do e += t.offsetLeft, o += t.offsetTop; while (t = t.offsetParent); return [e, o] }, h = function(e) { "use strict"; var o = document, i = function(e) { if ("object" != typeof window.google || !window.google.maps) return "object" == typeof window.console && window.console.error && console.error("Google Maps API is required. Please register the following JavaScript library https://maps.googleapis.com/maps/api/js."), function() {}; if (!this) return new i(e); e.zoom = e.zoom || 15, e.mapType = e.mapType || "roadmap"; var n, s = function(t, e) { return void 0 === t ? e : t }, h = this, d = ["bounds_changed", "center_changed", "click", "dblclick", "drag", "dragend", "dragstart", "idle", "maptypeid_changed", "projection_changed", "resize", "tilesloaded", "zoom_changed"], c = ["mousemove", "mouseout", "mouseover"], p = ["el", "lat", "lng", "mapType", "width", "height", "markerClusterer", "enableNewStyle"], u = e.el || e.div, f = e.markerClusterer, m = google.maps.MapTypeId[e.mapType.toUpperCase()], g = new google.maps.LatLng(e.lat, e.lng), v = s(e.zoomControl, !0), y = e.zoomControlOpt || { style: "DEFAULT", position: "TOP_LEFT" }, w = y.style || "DEFAULT", b = y.position || "TOP_LEFT", z = s(e.panControl, !0), T = s(e.mapTypeControl, !0), x = s(e.scaleControl, !0), k = s(e.streetViewControl, !0), C = s(C, !0), L = {}, S = { zoom: this.zoom, center: g, mapTypeId: m }, E = { panControl: z, zoomControl: v, zoomControlOptions: { style: google.maps.ZoomControlStyle[w], position: google.maps.ControlPosition[b] }, mapTypeControl: T, scaleControl: x, streetViewControl: k, overviewMapControl: C }; if ("string" == typeof e.el || "string" == typeof e.div ? u.indexOf("#") > -1 ? this.el = a(u, e.context) : this.el = r.apply(this, [u, e.context]) : this.el = u, "undefined" == typeof this.el || null === this.el) throw "No element defined."; for (window.context_menu = window.context_menu || {}, window.context_menu[h.el.id] = {}, this.controls = [], this.overlays = [], this.layers = [], this.singleLayers = {}, this.markers = [], this.polylines = [], this.routes = [], this.polygons = [], this.infoWindow = null, this.overlay_el = null, this.zoom = e.zoom, this.registered_events = {}, this.el.style.width = e.width || this.el.scrollWidth || this.el.offsetWidth, this.el.style.height = e.height || this.el.scrollHeight || this.el.offsetHeight, google.maps.visualRefresh = e.enableNewStyle, n = 0; n < p.length; n++) delete e[p[n]]; for (1 != e.disableDefaultUI && (S = t(S, E)), L = t(S, e), n = 0; n < d.length; n++) delete L[d[n]]; for (n = 0; n < c.length; n++) delete L[c[n]]; this.map = new google.maps.Map(this.el, L), f && (this.markerClusterer = f.apply(this, [this.map])); var W = function(t, e) { var o = "", i = window.context_menu[h.el.id][t]; for (var n in i) if (i.hasOwnProperty(n)) { var s = i[n]; o += '
  • ' + s.title + "
  • " } if (a("gmaps_context_menu")) { var r = a("gmaps_context_menu"); r.innerHTML = o; var n, d = r.getElementsByTagName("a"), c = d.length; for (n = 0; n < c; n++) { var p = d[n], u = function(o) { o.preventDefault(), i[this.id.replace(t + "_", "")].action.apply(h, [e]), h.hideContextMenu() }; google.maps.event.clearListeners(p, "click"), google.maps.event.addDomListenerOnce(p, "click", u, !1) } var f = l.apply(this, [h.el]), m = f[0] + e.pixel.x - 15, g = f[1] + e.pixel.y - 15; r.style.left = m + "px", r.style.top = g + "px" } }; this.buildContextMenu = function(t, e) { if ("marker" === t) { e.pixel = {}; var o = new google.maps.OverlayView; o.setMap(h.map), o.draw = function() { var i = o.getProjection(), n = e.marker.getPosition(); e.pixel = i.fromLatLngToContainerPixel(n), W(t, e) } } else W(t, e); var i = a("gmaps_context_menu"); setTimeout(function() { i.style.display = "block" }, 0) }, this.setContextMenu = function(t) { window.context_menu[h.el.id][t.control] = {}; var e, i = o.createElement("ul"); for (e in t.options) if (t.options.hasOwnProperty(e)) { var n = t.options[e]; window.context_menu[h.el.id][t.control][n.name] = { title: n.title, action: n.action } } i.id = "gmaps_context_menu", i.style.display = "none", i.style.position = "absolute", i.style.minWidth = "100px", i.style.background = "white", i.style.listStyle = "none", i.style.padding = "8px", i.style.boxShadow = "2px 2px 6px #ccc", a("gmaps_context_menu") || o.body.appendChild(i); var s = a("gmaps_context_menu"); google.maps.event.addDomListener(s, "mouseout", function(t) { t.relatedTarget && this.contains(t.relatedTarget) || window.setTimeout(function() { s.style.display = "none" }, 400) }, !1) }, this.hideContextMenu = function() { var t = a("gmaps_context_menu"); t && (t.style.display = "none") }; var O = function(t, o) { google.maps.event.addListener(t, o, function(t) { void 0 == t && (t = this), e[o].apply(this, [t]), h.hideContextMenu() }) }; google.maps.event.addListener(this.map, "zoom_changed", this.hideContextMenu); for (var _ = 0; _ < d.length; _++) { var I = d[_]; I in e && O(this.map, I) } for (var _ = 0; _ < c.length; _++) { var I = c[_]; I in e && O(this.map, I) } google.maps.event.addListener(this.map, "rightclick", function(t) { e.rightclick && e.rightclick.apply(this, [t]), void 0 != window.context_menu[h.el.id].map && h.buildContextMenu("map", t) }), this.refresh = function() { google.maps.event.trigger(this.map, "resize") }, this.fitZoom = function() { var t, e = [], o = this.markers.length; for (t = 0; t < o; t++) "boolean" == typeof this.markers[t].visible && this.markers[t].visible && e.push(this.markers[t].getPosition()); this.fitLatLngBounds(e) }, this.fitLatLngBounds = function(t) { var e, o = t.length, i = new google.maps.LatLngBounds; for (e = 0; e < o; e++) i.extend(t[e]); this.map.fitBounds(i) }, this.setCenter = function(t, e, o) { this.map.panTo(new google.maps.LatLng(t, e)), o && o() }, this.getElement = function() { return this.el }, this.zoomIn = function(t) { t = t || 1, this.zoom = this.map.getZoom() + t, this.map.setZoom(this.zoom) }, this.zoomOut = function(t) { t = t || 1, this.zoom = this.map.getZoom() - t, this.map.setZoom(this.zoom) }; var P, $ = []; for (P in this.map) "function" != typeof this.map[P] || this[P] || $.push(P); for (n = 0; n < $.length; n++) ! function(t, e, o) { t[o] = function() { return e[o].apply(e, arguments) } }(this, this.map, $[n]) }; return i }(this); h.prototype.createControl = function(t) { var e = document.createElement("div"); e.style.cursor = "pointer", t.disableDefaultStyles !== !0 && (e.style.fontFamily = "Roboto, Arial, sans-serif", e.style.fontSize = "11px", e.style.boxShadow = "rgba(0, 0, 0, 0.298039) 0px 1px 4px -1px"); for (var o in t.style) e.style[o] = t.style[o]; t.id && (e.id = t.id), t.title && (e.title = t.title), t.classes && (e.className = t.classes), t.content && ("string" == typeof t.content ? e.innerHTML = t.content : t.content instanceof HTMLElement && e.appendChild(t.content)), t.position && (e.position = google.maps.ControlPosition[t.position.toUpperCase()]); for (var i in t.events) ! function(e, o) { google.maps.event.addDomListener(e, o, function() { t.events[o].apply(this, [this]) }) }(e, i); return e.index = 1, e }, h.prototype.addControl = function(t) { var e = this.createControl(t); return this.controls.push(e), this.map.controls[e.position].push(e), e }, h.prototype.removeControl = function(t) { var e, o = null; for (e = 0; e < this.controls.length; e++) this.controls[e] == t && (o = this.controls[e].position, this.controls.splice(e, 1)); if (o) for (e = 0; e < this.map.controls.length; e++) { var i = this.map.controls[t.position]; if (i.getAt(e) == t) { i.removeAt(e); break } } return t }, h.prototype.createMarker = function(e) { if (void 0 == e.lat && void 0 == e.lng && void 0 == e.position) throw "No latitude or longitude defined."; var o = this, i = e.details, n = e.fences, s = e.outside, r = { position: new google.maps.LatLng(e.lat, e.lng), map: null }, a = t(r, e); delete a.lat, delete a.lng, delete a.fences, delete a.outside; var l = new google.maps.Marker(a); if (l.fences = n, e.infoWindow) { l.infoWindow = new google.maps.InfoWindow(e.infoWindow); for (var h = ["closeclick", "content_changed", "domready", "position_changed", "zindex_changed"], d = 0; d < h.length; d++) ! function(t, o) { e.infoWindow[o] && google.maps.event.addListener(t, o, function(t) { e.infoWindow[o].apply(this, [t]) }) }(l.infoWindow, h[d]) } for (var c = ["animation_changed", "clickable_changed", "cursor_changed", "draggable_changed", "flat_changed", "icon_changed", "position_changed", "shadow_changed", "shape_changed", "title_changed", "visible_changed", "zindex_changed"], p = ["dblclick", "drag", "dragend", "dragstart", "mousedown", "mouseout", "mouseover", "mouseup"], d = 0; d < c.length; d++) ! function(t, o) { e[o] && google.maps.event.addListener(t, o, function() { e[o].apply(this, [this]) }) }(l, c[d]); for (var d = 0; d < p.length; d++) ! function(t, o, i) { e[i] && google.maps.event.addListener(o, i, function(o) { o.pixel || (o.pixel = t.getProjection().fromLatLngToPoint(o.latLng)), e[i].apply(this, [o]) }) }(this.map, l, p[d]); return google.maps.event.addListener(l, "click", function() { this.details = i, e.click && e.click.apply(this, [this]), l.infoWindow && (o.hideInfoWindows(), l.infoWindow.open(o.map, l)) }), google.maps.event.addListener(l, "rightclick", function(t) { t.marker = this, e.rightclick && e.rightclick.apply(this, [t]), void 0 != window.context_menu[o.el.id].marker && o.buildContextMenu("marker", t) }), l.fences && google.maps.event.addListener(l, "dragend", function() { o.checkMarkerGeofence(l, function(t, e) { s(t, e) }) }), l }, h.prototype.addMarker = function(t) { var e; if (t.hasOwnProperty("gm_accessors_")) e = t; else { if (!(t.hasOwnProperty("lat") && t.hasOwnProperty("lng") || t.position)) throw "No latitude or longitude defined."; e = this.createMarker(t) } return e.setMap(this.map), this.markerClusterer && this.markerClusterer.addMarker(e), this.markers.push(e), h.fire("marker_added", e, this), e }, h.prototype.addMarkers = function(t) { for (var e, o = 0; e = t[o]; o++) this.addMarker(e); return this.markers }, h.prototype.hideInfoWindows = function() { for (var t, e = 0; t = this.markers[e]; e++) t.infoWindow && t.infoWindow.close() }, h.prototype.removeMarker = function(t) { for (var e = 0; e < this.markers.length; e++) if (this.markers[e] === t) { this.markers[e].setMap(null), this.markers.splice(e, 1), this.markerClusterer && this.markerClusterer.removeMarker(t), h.fire("marker_removed", t, this); break } return t }, h.prototype.removeMarkers = function(t) { var e = []; if ("undefined" == typeof t) { for (var o = 0; o < this.markers.length; o++) { var i = this.markers[o]; i.setMap(null), this.markerClusterer && this.markerClusterer.removeMarker(i), h.fire("marker_removed", i, this) } this.markers = e } else { for (var o = 0; o < t.length; o++) { var n = this.markers.indexOf(t[o]); if (n > -1) { var i = this.markers[n]; i.setMap(null), this.markerClusterer && this.markerClusterer.removeMarker(i), h.fire("marker_removed", i, this) } } for (var o = 0; o < this.markers.length; o++) { var i = this.markers[o]; null != i.getMap() && e.push(i) } this.markers = e } }, h.prototype.drawOverlay = function(t) { var e = new google.maps.OverlayView, o = !0; return e.setMap(this.map), null != t.auto_show && (o = t.auto_show), e.onAdd = function() { var o = document.createElement("div"); o.style.borderStyle = "none", o.style.borderWidth = "0px", o.style.position = "absolute", o.style.zIndex = 100, o.innerHTML = t.content, e.el = o, t.layer || (t.layer = "overlayLayer"); var i = this.getPanes(), n = i[t.layer], s = ["contextmenu", "DOMMouseScroll", "dblclick", "mousedown"]; n.appendChild(o); for (var r = 0; r < s.length; r++) ! function(t, e) { google.maps.event.addDomListener(t, e, function(t) { navigator.userAgent.toLowerCase().indexOf("msie") != -1 && document.all ? (t.cancelBubble = !0, t.returnValue = !1) : t.stopPropagation() }) }(o, s[r]); t.click && (i.overlayMouseTarget.appendChild(e.el), google.maps.event.addDomListener(e.el, "click", function() { t.click.apply(e, [e]) })), google.maps.event.trigger(this, "ready") }, e.draw = function() { var i = this.getProjection(), n = i.fromLatLngToDivPixel(new google.maps.LatLng(t.lat, t.lng)); t.horizontalOffset = t.horizontalOffset || 0, t.verticalOffset = t.verticalOffset || 0; var s = e.el, r = s.children[0], a = r.clientHeight, l = r.clientWidth; switch (t.verticalAlign) { case "top": s.style.top = n.y - a + t.verticalOffset + "px"; break; default: case "middle": s.style.top = n.y - a / 2 + t.verticalOffset + "px"; break; case "bottom": s.style.top = n.y + t.verticalOffset + "px" } switch (t.horizontalAlign) { case "left": s.style.left = n.x - l + t.horizontalOffset + "px"; break; default: case "center": s.style.left = n.x - l / 2 + t.horizontalOffset + "px"; break; case "right": s.style.left = n.x + t.horizontalOffset + "px" } s.style.display = o ? "block" : "none", o || t.show.apply(this, [s]) }, e.onRemove = function() { var o = e.el; t.remove ? t.remove.apply(this, [o]) : (e.el.parentNode.removeChild(e.el), e.el = null) }, this.overlays.push(e), e }, h.prototype.removeOverlay = function(t) { for (var e = 0; e < this.overlays.length; e++) if (this.overlays[e] === t) { this.overlays[e].setMap(null), this.overlays.splice(e, 1); break } }, h.prototype.removeOverlays = function() { for (var t, e = 0; t = this.overlays[e]; e++) t.setMap(null); this.overlays = [] }, h.prototype.drawPolyline = function(t) { var e = [], o = t.path; if (o.length) if (void 0 === o[0][0]) e = o; else for (var i, n = 0; i = o[n]; n++) e.push(new google.maps.LatLng(i[0], i[1])); var s = { map: this.map, path: e, strokeColor: t.strokeColor, strokeOpacity: t.strokeOpacity, strokeWeight: t.strokeWeight, geodesic: t.geodesic, clickable: !0, editable: !1, visible: !0 }; t.hasOwnProperty("clickable") && (s.clickable = t.clickable), t.hasOwnProperty("editable") && (s.editable = t.editable), t.hasOwnProperty("icons") && (s.icons = t.icons), t.hasOwnProperty("zIndex") && (s.zIndex = t.zIndex); for (var r = new google.maps.Polyline(s), a = ["click", "dblclick", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "rightclick"], l = 0; l < a.length; l++) ! function(e, o) { t[o] && google.maps.event.addListener(e, o, function(e) { t[o].apply(this, [e]) }) }(r, a[l]); return this.polylines.push(r), h.fire("polyline_added", r, this), r }, h.prototype.removePolyline = function(t) { for (var e = 0; e < this.polylines.length; e++) if (this.polylines[e] === t) { this.polylines[e].setMap(null), this.polylines.splice(e, 1), h.fire("polyline_removed", t, this); break } }, h.prototype.removePolylines = function() { for (var t, e = 0; t = this.polylines[e]; e++) t.setMap(null); this.polylines = [] }, h.prototype.drawCircle = function(e) { e = t({ map: this.map, center: new google.maps.LatLng(e.lat, e.lng) }, e), delete e.lat, delete e.lng; for (var o = new google.maps.Circle(e), i = ["click", "dblclick", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "rightclick"], n = 0; n < i.length; n++) ! function(t, o) { e[o] && google.maps.event.addListener(t, o, function(t) { e[o].apply(this, [t]) }) }(o, i[n]); return this.polygons.push(o), o }, h.prototype.drawRectangle = function(e) { e = t({ map: this.map }, e); var o = new google.maps.LatLngBounds(new google.maps.LatLng(e.bounds[0][0], e.bounds[0][1]), new google.maps.LatLng(e.bounds[1][0], e.bounds[1][1])); e.bounds = o; for (var i = new google.maps.Rectangle(e), n = ["click", "dblclick", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "rightclick"], s = 0; s < n.length; s++) ! function(t, o) { e[o] && google.maps.event.addListener(t, o, function(t) { e[o].apply(this, [t]) }) }(i, n[s]); return this.polygons.push(i), i }, h.prototype.drawPolygon = function(e) { var n = !1; e.hasOwnProperty("useGeoJSON") && (n = e.useGeoJSON), delete e.useGeoJSON, e = t({ map: this.map }, e), 0 == n && (e.paths = [e.paths.slice(0)]), e.paths.length > 0 && e.paths[0].length > 0 && (e.paths = i(o(e.paths, s, n))); for (var r = new google.maps.Polygon(e), a = ["click", "dblclick", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "rightclick"], l = 0; l < a.length; l++) ! function(t, o) { e[o] && google.maps.event.addListener(t, o, function(t) { e[o].apply(this, [t]) }) }(r, a[l]); return this.polygons.push(r), h.fire("polygon_added", r, this), r }, h.prototype.removePolygon = function(t) { for (var e = 0; e < this.polygons.length; e++) if (this.polygons[e] === t) { this.polygons[e].setMap(null), this.polygons.splice(e, 1), h.fire("polygon_removed", t, this); break } }, h.prototype.removePolygons = function() { for (var t, e = 0; t = this.polygons[e]; e++) t.setMap(null); this.polygons = [] }, h.prototype.getFromFusionTables = function(t) { var e = t.events; delete t.events; var o = t, i = new google.maps.FusionTablesLayer(o); for (var n in e) ! function(t, o) { google.maps.event.addListener(t, o, function(t) { e[o].apply(this, [t]) }) }(i, n); return this.layers.push(i), i }, h.prototype.loadFromFusionTables = function(t) { var e = this.getFromFusionTables(t); return e.setMap(this.map), e }, h.prototype.getFromKML = function(t) { var e = t.url, o = t.events; delete t.url, delete t.events; var i = t, n = new google.maps.KmlLayer(e, i); for (var s in o) ! function(t, e) { google.maps.event.addListener(t, e, function(t) { o[e].apply(this, [t]) }) }(n, s); return this.layers.push(n), n }, h.prototype.loadFromKML = function(t) { var e = this.getFromKML(t); return e.setMap(this.map), e }, h.prototype.addLayer = function(t, e) { e = e || {}; var o; switch (t) { case "weather": this.singleLayers.weather = o = new google.maps.weather.WeatherLayer; break; case "clouds": this.singleLayers.clouds = o = new google.maps.weather.CloudLayer; break; case "traffic": this.singleLayers.traffic = o = new google.maps.TrafficLayer; break; case "transit": this.singleLayers.transit = o = new google.maps.TransitLayer; break; case "bicycling": this.singleLayers.bicycling = o = new google.maps.BicyclingLayer; break; case "panoramio": this.singleLayers.panoramio = o = new google.maps.panoramio.PanoramioLayer, o.setTag(e.filter), delete e.filter, e.click && google.maps.event.addListener(o, "click", function(t) { e.click(t), delete e.click }); break; case "places": if (this.singleLayers.places = o = new google.maps.places.PlacesService(this.map), e.search || e.nearbySearch || e.radarSearch) { var i = { bounds: e.bounds || null, keyword: e.keyword || null, location: e.location || null, name: e.name || null, radius: e.radius || null, rankBy: e.rankBy || null, types: e.types || null }; e.radarSearch && o.radarSearch(i, e.radarSearch), e.search && o.search(i, e.search), e.nearbySearch && o.nearbySearch(i, e.nearbySearch) } if (e.textSearch) { var n = { bounds: e.bounds || null, location: e.location || null, query: e.query || null, radius: e.radius || null }; o.textSearch(n, e.textSearch) } } if (void 0 !== o) return "function" == typeof o.setOptions && o.setOptions(e), "function" == typeof o.setMap && o.setMap(this.map), o }, h.prototype.removeLayer = function(t) { if ("string" == typeof t && void 0 !== this.singleLayers[t]) this.singleLayers[t].setMap(null), delete this.singleLayers[t]; else for (var e = 0; e < this.layers.length; e++) if (this.layers[e] === t) { this.layers[e].setMap(null), this.layers.splice(e, 1); break } }; var d, c; return h.prototype.getRoutes = function(e) { switch (e.travelMode) { case "bicycling": d = google.maps.TravelMode.BICYCLING; break; case "transit": d = google.maps.TravelMode.TRANSIT; break; case "driving": d = google.maps.TravelMode.DRIVING; break; default: d = google.maps.TravelMode.WALKING } c = "imperial" === e.unitSystem ? google.maps.UnitSystem.IMPERIAL : google.maps.UnitSystem.METRIC; var o = { avoidHighways: !1, avoidTolls: !1, optimizeWaypoints: !1, waypoints: [] }, i = t(o, e); i.origin = /string/.test(typeof e.origin) ? e.origin : new google.maps.LatLng(e.origin[0], e.origin[1]), i.destination = /string/.test(typeof e.destination) ? e.destination : new google.maps.LatLng(e.destination[0], e.destination[1]), i.travelMode = d, i.unitSystem = c, delete i.callback, delete i.error; var n = this, s = new google.maps.DirectionsService; s.route(i, function(t, o) { if (o === google.maps.DirectionsStatus.OK) { for (var i in t.routes) t.routes.hasOwnProperty(i) && n.routes.push(t.routes[i]); e.callback && e.callback(n.routes, t, o) } else e.error && e.error(t, o) }) }, h.prototype.removeRoutes = function() { this.routes.length = 0 }, h.prototype.getElevations = function(e) { e = t({ locations: [], path: !1, samples: 256 }, e), e.locations.length > 0 && e.locations[0].length > 0 && (e.locations = i(o([e.locations], s, !1))); var n = e.callback; delete e.callback; var r = new google.maps.ElevationService; if (e.path) { var a = { path: e.locations, samples: e.samples }; r.getElevationAlongPath(a, function(t, e) { n && "function" == typeof n && n(t, e) }) } else delete e.path, delete e.samples, r.getElevationForLocations(e, function(t, e) { n && "function" == typeof n && n(t, e) }) }, h.prototype.cleanRoute = h.prototype.removePolylines, h.prototype.renderRoute = function(e, o) { var i, n = "string" == typeof o.panel ? document.getElementById(o.panel.replace("#", "")) : o.panel; o.panel = n, o = t({ map: this.map }, o), i = new google.maps.DirectionsRenderer(o), this.getRoutes({ origin: e.origin, destination: e.destination, travelMode: e.travelMode, waypoints: e.waypoints, unitSystem: e.unitSystem, error: e.error, avoidHighways: e.avoidHighways, avoidTolls: e.avoidTolls, optimizeWaypoints: e.optimizeWaypoints, callback: function(t, e, o) { o === google.maps.DirectionsStatus.OK && i.setDirections(e) } }) }, h.prototype.drawRoute = function(t) { var e = this; this.getRoutes({ origin: t.origin, destination: t.destination, travelMode: t.travelMode, waypoints: t.waypoints, unitSystem: t.unitSystem, error: t.error, avoidHighways: t.avoidHighways, avoidTolls: t.avoidTolls, optimizeWaypoints: t.optimizeWaypoints, callback: function(o) { if (o.length > 0) { var i = { path: o[o.length - 1].overview_path, strokeColor: t.strokeColor, strokeOpacity: t.strokeOpacity, strokeWeight: t.strokeWeight }; t.hasOwnProperty("icons") && (i.icons = t.icons), e.drawPolyline(i), t.callback && t.callback(o[o.length - 1]) } } }) }, h.prototype.travelRoute = function(t) { if (t.origin && t.destination) this.getRoutes({ origin: t.origin, destination: t.destination, travelMode: t.travelMode, waypoints: t.waypoints, unitSystem: t.unitSystem, error: t.error, callback: function(e) { if (e.length > 0 && t.start && t.start(e[e.length - 1]), e.length > 0 && t.step) { var o = e[e.length - 1]; if (o.legs.length > 0) for (var i, n = o.legs[0].steps, s = 0; i = n[s]; s++) i.step_number = s, t.step(i, o.legs[0].steps.length - 1) } e.length > 0 && t.end && t.end(e[e.length - 1]) } }); else if (t.route && t.route.legs.length > 0) for (var e, o = t.route.legs[0].steps, i = 0; e = o[i]; i++) e.step_number = i, t.step(e) }, h.prototype.drawSteppedRoute = function(t) { var e = this; if (t.origin && t.destination) this.getRoutes({ origin: t.origin, destination: t.destination, travelMode: t.travelMode, waypoints: t.waypoints, error: t.error, callback: function(o) { if (o.length > 0 && t.start && t.start(o[o.length - 1]), o.length > 0 && t.step) { var i = o[o.length - 1]; if (i.legs.length > 0) for (var n, s = i.legs[0].steps, r = 0; n = s[r]; r++) { n.step_number = r; var a = { path: n.path, strokeColor: t.strokeColor, strokeOpacity: t.strokeOpacity, strokeWeight: t.strokeWeight }; t.hasOwnProperty("icons") && (a.icons = t.icons), e.drawPolyline(a), t.step(n, i.legs[0].steps.length - 1) } } o.length > 0 && t.end && t.end(o[o.length - 1]) } }); else if (t.route && t.route.legs.length > 0) for (var o, i = t.route.legs[0].steps, n = 0; o = i[n]; n++) { o.step_number = n; var s = { path: o.path, strokeColor: t.strokeColor, strokeOpacity: t.strokeOpacity, strokeWeight: t.strokeWeight }; t.hasOwnProperty("icons") && (s.icons = t.icons), e.drawPolyline(s), t.step(o) } }, h.Route = function(t) { this.origin = t.origin, this.destination = t.destination, this.waypoints = t.waypoints, this.map = t.map, this.route = t.route, this.step_count = 0, this.steps = this.route.legs[0].steps, this.steps_length = this.steps.length; var e = { path: new google.maps.MVCArray, strokeColor: t.strokeColor, strokeOpacity: t.strokeOpacity, strokeWeight: t.strokeWeight }; t.hasOwnProperty("icons") && (e.icons = t.icons), this.polyline = this.map.drawPolyline(e).getPath() }, h.Route.prototype.getRoute = function(t) { var o = this; this.map.getRoutes({ origin: this.origin, destination: this.destination, travelMode: t.travelMode, waypoints: this.waypoints || [], error: t.error, callback: function() { o.route = e[0], t.callback && t.callback.call(o) } }) }, h.Route.prototype.back = function() { if (this.step_count > 0) { this.step_count--; var t = this.route.legs[0].steps[this.step_count].path; for (var e in t) t.hasOwnProperty(e) && this.polyline.pop() } }, h.Route.prototype.forward = function() { if (this.step_count < this.steps_length) { var t = this.route.legs[0].steps[this.step_count].path; for (var e in t) t.hasOwnProperty(e) && this.polyline.push(t[e]); this.step_count++ } }, h.prototype.checkGeofence = function(t, e, o) { return o.containsLatLng(new google.maps.LatLng(t, e)) }, h.prototype.checkMarkerGeofence = function(t, e) { if (t.fences) for (var o, i = 0; o = t.fences[i]; i++) { var n = t.getPosition(); this.checkGeofence(n.lat(), n.lng(), o) || e(t, o) } }, h.prototype.toImage = function(t) { var t = t || {}, e = {}; if (e.size = t.size || [this.el.clientWidth, this.el.clientHeight], e.lat = this.getCenter().lat(), e.lng = this.getCenter().lng(), this.markers.length > 0) { e.markers = []; for (var o = 0; o < this.markers.length; o++) e.markers.push({ lat: this.markers[o].getPosition().lat(), lng: this.markers[o].getPosition().lng() }) } if (this.polylines.length > 0) { var i = this.polylines[0]; e.polyline = {}, e.polyline.path = google.maps.geometry.encoding.encodePath(i.getPath()), e.polyline.strokeColor = i.strokeColor, e.polyline.strokeOpacity = i.strokeOpacity, e.polyline.strokeWeight = i.strokeWeight } return h.staticMapURL(e) }, h.staticMapURL = function(t) { function e(t, e) { if ("#" === t[0] && (t = t.replace("#", "0x"), e)) { if (e = parseFloat(e), e = Math.min(1, Math.max(e, 0)), 0 === e) return "0x00000000"; e = (255 * e).toString(16), 1 === e.length && (e += e), t = t.slice(0, 8) + e } return t } var o, i = [], n = ("file:" === location.protocol ? "http:" : location.protocol) + "//maps.googleapis.com/maps/api/staticmap"; t.url && (n = t.url, delete t.url), n += "?"; var s = t.markers; delete t.markers, !s && t.marker && (s = [t.marker], delete t.marker); var r = t.styles; delete t.styles; var a = t.polyline; if (delete t.polyline, t.center) i.push("center=" + t.center), delete t.center; else if (t.address) i.push("center=" + t.address), delete t.address; else if (t.lat) i.push(["center=", t.lat, ",", t.lng].join("")), delete t.lat, delete t.lng; else if (t.visible) { var l = encodeURI(t.visible.join("|")); i.push("visible=" + l) } var h = t.size; h ? (h.join && (h = h.join("x")), delete t.size) : h = "630x300", i.push("size=" + h), t.zoom || t.zoom === !1 || (t.zoom = 15); var d = !t.hasOwnProperty("sensor") || !!t.sensor; delete t.sensor, i.push("sensor=" + d); for (var c in t) t.hasOwnProperty(c) && i.push(c + "=" + t[c]); if (s) for (var p, u, f = 0; o = s[f]; f++) { p = [], o.size && "normal" !== o.size ? (p.push("size:" + o.size), delete o.size) : o.icon && (p.push("icon:" + encodeURI(o.icon)), delete o.icon), o.color && (p.push("color:" + o.color.replace("#", "0x")), delete o.color), o.label && (p.push("label:" + o.label[0].toUpperCase()), delete o.label), u = o.address ? o.address : o.lat + "," + o.lng, delete o.address, delete o.lat, delete o.lng; for (var c in o) o.hasOwnProperty(c) && p.push(c + ":" + o[c]); p.length || 0 === f ? (p.push(u), p = p.join("|"), i.push("markers=" + encodeURI(p))) : (p = i.pop() + encodeURI("|" + u), i.push(p)) } if (r) for (var f = 0; f < r.length; f++) { var m = []; r[f].featureType && m.push("feature:" + r[f].featureType.toLowerCase()), r[f].elementType && m.push("element:" + r[f].elementType.toLowerCase()); for (var g = 0; g < r[f].stylers.length; g++) for (var v in r[f].stylers[g]) { var y = r[f].stylers[g][v]; "hue" != v && "color" != v || (y = "0x" + y.substring(1)), m.push(v + ":" + y) } var w = m.join("|"); "" != w && i.push("style=" + w) } if (a) { if (o = a, a = [], o.strokeWeight && a.push("weight:" + parseInt(o.strokeWeight, 10)), o.strokeColor) { var b = e(o.strokeColor, o.strokeOpacity); a.push("color:" + b) } if (o.fillColor) { var z = e(o.fillColor, o.fillOpacity); a.push("fillcolor:" + z) } var T = o.path; if (T.join) for (var x, g = 0; x = T[g]; g++) a.push(x.join(",")); else a.push("enc:" + T); a = a.join("|"), i.push("path=" + encodeURI(a)) } var k = window.devicePixelRatio || 1; return i.push("scale=" + k), i = i.join("&"), n + i }, h.prototype.addMapType = function(t, e) { if (!e.hasOwnProperty("getTileUrl") || "function" != typeof e.getTileUrl) throw "'getTileUrl' function required."; e.tileSize = e.tileSize || new google.maps.Size(256, 256); var o = new google.maps.ImageMapType(e); this.map.mapTypes.set(t, o) }, h.prototype.addOverlayMapType = function(t) { if (!t.hasOwnProperty("getTile") || "function" != typeof t.getTile) throw "'getTile' function required."; var e = t.index; delete t.index, this.map.overlayMapTypes.insertAt(e, t) }, h.prototype.removeOverlayMapType = function(t) { this.map.overlayMapTypes.removeAt(t) }, h.prototype.addStyle = function(t) { var e = new google.maps.StyledMapType(t.styles, { name: t.styledMapName }); this.map.mapTypes.set(t.mapTypeId, e) }, h.prototype.setStyle = function(t) { this.map.setMapTypeId(t) }, h.prototype.createPanorama = function(t) { return t.hasOwnProperty("lat") && t.hasOwnProperty("lng") || (t.lat = this.getCenter().lat(), t.lng = this.getCenter().lng()), this.panorama = h.createPanorama(t), this.map.setStreetView(this.panorama), this.panorama }, h.createPanorama = function(e) { var o = a(e.el, e.context); e.position = new google.maps.LatLng(e.lat, e.lng), delete e.el, delete e.context, delete e.lat, delete e.lng; for (var i = ["closeclick", "links_changed", "pano_changed", "position_changed", "pov_changed", "resize", "visible_changed"], n = t({ visible: !0 }, e), s = 0; s < i.length; s++) delete n[i[s]]; for (var r = new google.maps.StreetViewPanorama(o, n), s = 0; s < i.length; s++) ! function(t, o) { e[o] && google.maps.event.addListener(t, o, function() { e[o].apply(this) }) }(r, i[s]); return r }, h.prototype.on = function(t, e) { return h.on(t, this, e) }, h.prototype.off = function(t) { h.off(t, this) }, h.prototype.once = function(t, e) { return h.once(t, this, e) }, h.custom_events = ["marker_added", "marker_removed", "polyline_added", "polyline_removed", "polygon_added", "polygon_removed", "geolocated", "geolocation_failed"], h.on = function(t, e, o) { if (h.custom_events.indexOf(t) == -1) return e instanceof h && (e = e.map), google.maps.event.addListener(e, t, o); var i = { handler: o, eventName: t }; return e.registered_events[t] = e.registered_events[t] || [], e.registered_events[t].push(i), i }, h.off = function(t, e) { h.custom_events.indexOf(t) == -1 ? (e instanceof h && (e = e.map), google.maps.event.clearListeners(e, t)) : e.registered_events[t] = [] }, h.once = function(t, e, o) { if (h.custom_events.indexOf(t) == -1) return e instanceof h && (e = e.map), google.maps.event.addListenerOnce(e, t, o) }, h.fire = function(t, e, o) { if (h.custom_events.indexOf(t) == -1) google.maps.event.trigger(e, t, Array.prototype.slice.apply(arguments).slice(2)); else if (t in o.registered_events) for (var i = o.registered_events[t], n = 0; n < i.length; n++) ! function(t, e, o) { t.apply(e, [o]) }(i[n].handler, o, e) }, h.geolocate = function(t) { var e = t.always || t.complete; navigator.geolocation ? navigator.geolocation.getCurrentPosition(function(o) { t.success(o), e && e() }, function(o) { t.error(o), e && e() }, t.options) : (t.not_supported(), e && e()) }, h.geocode = function(t) { this.geocoder = new google.maps.Geocoder; var e = t.callback; t.hasOwnProperty("lat") && t.hasOwnProperty("lng") && (t.latLng = new google.maps.LatLng(t.lat, t.lng)), delete t.lat, delete t.lng, delete t.callback, this.geocoder.geocode(t, function(t, o) { e(t, o) }) }, "object" == typeof window.google && window.google.maps && (google.maps.Polygon.prototype.getBounds || (google.maps.Polygon.prototype.getBounds = function(t) { for (var e, o = new google.maps.LatLngBounds, i = this.getPaths(), n = 0; n < i.getLength(); n++) { e = i.getAt(n); for (var s = 0; s < e.getLength(); s++) o.extend(e.getAt(s)) } return o }), google.maps.Polygon.prototype.containsLatLng || (google.maps.Polygon.prototype.containsLatLng = function(t) { var e = this.getBounds(); if (null !== e && !e.contains(t)) return !1; for (var o = !1, i = this.getPaths().getLength(), n = 0; n < i; n++) for (var s = this.getPaths().getAt(n), r = s.getLength(), a = r - 1, l = 0; l < r; l++) { var h = s.getAt(l), d = s.getAt(a); (h.lng() < t.lng() && d.lng() >= t.lng() || d.lng() < t.lng() && h.lng() >= t.lng()) && h.lat() + (t.lng() - h.lng()) / (d.lng() - h.lng()) * (d.lat() - h.lat()) < t.lat() && (o = !o), a = l } return o }), google.maps.Circle.prototype.containsLatLng || (google.maps.Circle.prototype.containsLatLng = function(t) { return !google.maps.geometry || google.maps.geometry.spherical.computeDistanceBetween(this.getCenter(), t) <= this.getRadius() }), google.maps.LatLngBounds.prototype.containsLatLng = function(t) { return this.contains(t) }, google.maps.Marker.prototype.setFences = function(t) { this.fences = t }, google.maps.Marker.prototype.addFence = function(t) { this.fences.push(t) }, google.maps.Marker.prototype.getId = function() { return this.__gm_id }), Array.prototype.indexOf || (Array.prototype.indexOf = function(t) { "use strict"; if (null == this) throw new TypeError; var e = Object(this), o = e.length >>> 0; if (0 === o) return -1; var i = 0; if (arguments.length > 1 && (i = Number(arguments[1]), i != i ? i = 0 : 0 != i && i != 1 / 0 && i != -(1 / 0) && (i = (i > 0 || -1) * Math.floor(Math.abs(i)))), i >= o) return -1; for (var n = i >= 0 ? i : Math.max(o - Math.abs(i), 0); n < o; n++) if (n in e && e[n] === t) return n; return -1 }), h }), function() { function t() {} function e(t, e) { for (var o = t.length; o--;) if (t[o].listener === e) return o; return -1 } function o(t) { return function() { return this[t].apply(this, arguments) } } var i = t.prototype, n = this, s = n.EventEmitter; i.getListeners = function(t) { var e, o, i = this._getEvents(); if ("object" == typeof t) { e = {}; for (o in i) i.hasOwnProperty(o) && t.test(o) && (e[o] = i[o]) } else e = i[t] || (i[t] = []); return e }, i.flattenListeners = function(t) { var e, o = []; for (e = 0; e < t.length; e += 1) o.push(t[e].listener); return o }, i.getListenersAsObject = function(t) { var e, o = this.getListeners(t); return o instanceof Array && (e = {}, e[t] = o), e || o }, i.addListener = function(t, o) { var i, n = this.getListenersAsObject(t), s = "object" == typeof o; for (i in n) n.hasOwnProperty(i) && e(n[i], o) === -1 && n[i].push(s ? o : { listener: o, once: !1 }); return this }, i.on = o("addListener"), i.addOnceListener = function(t, e) { return this.addListener(t, { listener: e, once: !0 }) }, i.once = o("addOnceListener"), i.defineEvent = function(t) { return this.getListeners(t), this }, i.defineEvents = function(t) { for (var e = 0; e < t.length; e += 1) this.defineEvent(t[e]); return this }, i.removeListener = function(t, o) { var i, n, s = this.getListenersAsObject(t); for (n in s) s.hasOwnProperty(n) && (i = e(s[n], o), i !== -1 && s[n].splice(i, 1)); return this }, i.off = o("removeListener"), i.addListeners = function(t, e) { return this.manipulateListeners(!1, t, e) }, i.removeListeners = function(t, e) { return this.manipulateListeners(!0, t, e) }, i.manipulateListeners = function(t, e, o) { var i, n, s = t ? this.removeListener : this.addListener, r = t ? this.removeListeners : this.addListeners; if ("object" != typeof e || e instanceof RegExp) for (i = o.length; i--;) s.call(this, e, o[i]); else for (i in e) e.hasOwnProperty(i) && (n = e[i]) && ("function" == typeof n ? s.call(this, i, n) : r.call(this, i, n)); return this }, i.removeEvent = function(t) { var e, o = typeof t, i = this._getEvents(); if ("string" === o) delete i[t]; else if ("object" === o) for (e in i) i.hasOwnProperty(e) && t.test(e) && delete i[e]; else delete this._events; return this }, i.removeAllListeners = o("removeEvent"), i.emitEvent = function(t, e) { var o, i, n, s, r = this.getListenersAsObject(t); for (n in r) if (r.hasOwnProperty(n)) for (i = r[n].length; i--;) o = r[n][i], o.once === !0 && this.removeListener(t, o.listener), s = o.listener.apply(this, e || []), s === this._getOnceReturnValue() && this.removeListener(t, o.listener); return this }, i.trigger = o("emitEvent"), i.emit = function(t) { var e = Array.prototype.slice.call(arguments, 1); return this.emitEvent(t, e) }, i.setOnceReturnValue = function(t) { return this._onceReturnValue = t, this }, i._getOnceReturnValue = function() { return !this.hasOwnProperty("_onceReturnValue") || this._onceReturnValue }, i._getEvents = function() { return this._events || (this._events = {}) }, t.noConflict = function() { return n.EventEmitter = s, t }, "function" == typeof define && define.amd ? define("eventEmitter/EventEmitter", [], function() { return t }) : "object" == typeof module && module.exports ? module.exports = t : this.EventEmitter = t }.call(this), function(t) { function e(e) { var o = t.event; return o.target = o.target || o.srcElement || e, o } var o = document.documentElement, i = function() {}; o.addEventListener ? i = function(t, e, o) { t.addEventListener(e, o, !1) } : o.attachEvent && (i = function(t, o, i) { t[o + i] = i.handleEvent ? function() { var o = e(t); i.handleEvent.call(i, o) } : function() { var o = e(t); i.call(t, o) }, t.attachEvent("on" + o, t[o + i]) }); var n = function() {}; o.removeEventListener ? n = function(t, e, o) { t.removeEventListener(e, o, !1) } : o.detachEvent && (n = function(t, e, o) { t.detachEvent("on" + e, t[e + o]); try { delete t[e + o] } catch (i) { t[e + o] = void 0 } }); var s = { bind: i, unbind: n }; "function" == typeof define && define.amd ? define("eventie/eventie", s) : t.eventie = s }(this), function(t) { function e(t, e) { for (var o in e) t[o] = e[o]; return t } function o(t) { return "[object Array]" === l.call(t) } function i(t) { var e = []; if (o(t)) e = t; else if ("number" == typeof t.length) for (var i = 0, n = t.length; i < n; i++) e.push(t[i]); else e.push(t); return e } function n(t, o) { function n(t, o, r) { if (!(this instanceof n)) return new n(t, o); "string" == typeof t && (t = document.querySelectorAll(t)), this.elements = i(t), this.options = e({}, this.options), "function" == typeof o ? r = o : e(this.options, o), r && this.on("always", r), this.getImages(), s && (this.jqDeferred = new s.Deferred); var a = this; setTimeout(function() { a.check() }) } function l(t) { this.img = t } function h(t) { this.src = t, d[t] = this } n.prototype = new t, n.prototype.options = {}, n.prototype.getImages = function() { this.images = []; for (var t = 0, e = this.elements.length; t < e; t++) { var o = this.elements[t]; "IMG" === o.nodeName && this.addImage(o); for (var i = o.querySelectorAll("img"), n = 0, s = i.length; n < s; n++) { var r = i[n]; this.addImage(r) } } }, n.prototype.addImage = function(t) { var e = new l(t); this.images.push(e) }, n.prototype.check = function() { function t(t, n) { return e.options.debug && a && r.log("confirm", t, n), e.progress(t), o++, o === i && e.complete(), !0 } var e = this, o = 0, i = this.images.length; if (this.hasAnyBroken = !1, !i) return void this.complete(); for (var n = 0; n < i; n++) { var s = this.images[n]; s.on("confirm", t), s.check() } }, n.prototype.progress = function(t) { this.hasAnyBroken = this.hasAnyBroken || !t.isLoaded; var e = this; setTimeout(function() { e.emit("progress", e, t), e.jqDeferred && e.jqDeferred.notify(e, t) }) }, n.prototype.complete = function() { var t = this.hasAnyBroken ? "fail" : "done"; this.isComplete = !0; var e = this; setTimeout(function() { if (e.emit(t, e), e.emit("always", e), e.jqDeferred) { var o = e.hasAnyBroken ? "reject" : "resolve"; e.jqDeferred[o](e) } }) }, s && (s.fn.imagesLoaded = function(t, e) { var o = new n(this, t, e); return o.jqDeferred.promise(s(this)) }), l.prototype = new t, l.prototype.check = function() { var t = d[this.img.src] || new h(this.img.src); if (t.isConfirmed) return void this.confirm(t.isLoaded, "cached was confirmed"); if (this.img.complete && void 0 !== this.img.naturalWidth) return void this.confirm(0 !== this.img.naturalWidth, "naturalWidth"); var e = this; t.on("confirm", function(t, o) { return e.confirm(t.isLoaded, o), !0 }), t.check() }, l.prototype.confirm = function(t, e) { this.isLoaded = t, this.emit("confirm", this, e) }; var d = {}; return h.prototype = new t, h.prototype.check = function() { if (!this.isChecked) { var t = new Image; o.bind(t, "load", this), o.bind(t, "error", this), t.src = this.src, this.isChecked = !0 } }, h.prototype.handleEvent = function(t) { var e = "on" + t.type; this[e] && this[e](t) }, h.prototype.onload = function(t) { this.confirm(!0, "onload"), this.unbindProxyEvents(t) }, h.prototype.onerror = function(t) { this.confirm(!1, "onerror"), this.unbindProxyEvents(t) }, h.prototype.confirm = function(t, e) { this.isConfirmed = !0, this.isLoaded = t, this.emit("confirm", this, e) }, h.prototype.unbindProxyEvents = function(t) { o.unbind(t.target, "load", this), o.unbind(t.target, "error", this) }, n } var s = t.jQuery, r = t.console, a = "undefined" != typeof r, l = Object.prototype.toString; "function" == typeof define && define.amd ? define(["eventEmitter/EventEmitter", "eventie/eventie"], n) : t.imagesLoaded = n(t.EventEmitter, t.eventie) }(window), "function" != typeof Object.create && (Object.create = function(t) { function e() {} return e.prototype = t, new e }), function(t, e, o, i) { var n = { init: function(e, o) { var i = this; i.elem = o, i.$elem = t(o), i.imageSrc = i.$elem.data("zoom-image") ? i.$elem.data("zoom-image") : i.$elem.attr("src"), i.options = t.extend({}, t.fn.elevateZoom.options, e), i.options.tint && (i.options.lensColour = "none", i.options.lensOpacity = "1"), "inner" == i.options.zoomType && (i.options.showLens = !1), i.$elem.parent().removeAttr("title").removeAttr("alt"), i.zoomImage = i.imageSrc, i.refresh(1), t("#" + i.options.gallery + " a").click(function(e) { return i.options.galleryActiveClass && (t("#" + i.options.gallery + " a").removeClass(i.options.galleryActiveClass), t(this).addClass(i.options.galleryActiveClass)), e.preventDefault(), t(this).data("zoom-image") ? i.zoomImagePre = t(this).data("zoom-image") : i.zoomImagePre = t(this).data("image"), i.swaptheimage(t(this).data("image"), i.zoomImagePre), !1 }) }, refresh: function(t) { var e = this; setTimeout(function() { e.fetch(e.imageSrc) }, t || e.options.refresh) }, fetch: function(t) { var e = this, o = new Image; o.onload = function() { e.largeWidth = o.width, e.largeHeight = o.height, e.startZoom(), e.currentImage = e.imageSrc, e.options.onZoomedImageLoaded(e.$elem) }, o.src = t }, startZoom: function() { var e = this; if (e.nzWidth = e.$elem.width(), e.nzHeight = e.$elem.height(), e.isWindowActive = !1, e.isLensActive = !1, e.isTintActive = !1, e.overWindow = !1, e.options.imageCrossfade && (e.zoomWrap = e.$elem.wrap('
    '), e.$elem.css("position", "absolute")), e.zoomLock = 1, e.scrollingLock = !1, e.changeBgSize = !1, e.currentZoomLevel = e.options.zoomLevel, e.nzOffset = e.$elem.offset(), e.widthRatio = e.largeWidth / e.currentZoomLevel / e.nzWidth, e.heightRatio = e.largeHeight / e.currentZoomLevel / e.nzHeight, "window" == e.options.zoomType && (e.zoomWindowStyle = "overflow: hidden;background-position: 0px 0px;text-align:center;background-color: " + String(e.options.zoomWindowBgColour) + ";width: " + String(e.options.zoomWindowWidth) + "px;height: " + String(e.options.zoomWindowHeight) + "px;float: left;background-size: " + e.largeWidth / e.currentZoomLevel + "px " + e.largeHeight / e.currentZoomLevel + "px;display: none;z-index:100;border: " + String(e.options.borderSize) + "px solid " + e.options.borderColour + ";background-repeat: no-repeat;position: absolute;"), "inner" == e.options.zoomType) { var o = e.$elem.css("border-left-width"); e.zoomWindowStyle = "overflow: hidden;margin-left: " + String(o) + ";margin-top: " + String(o) + ";background-position: 0px 0px;width: " + String(e.nzWidth) + "px;height: " + String(e.nzHeight) + "px;float: left;display: none;cursor:" + e.options.cursor + ";px solid " + e.options.borderColour + ";background-repeat: no-repeat;position: absolute;" } "window" == e.options.zoomType && (lensHeight = e.nzHeight < e.options.zoomWindowWidth / e.widthRatio ? e.nzHeight : String(e.options.zoomWindowHeight / e.heightRatio), lensWidth = e.largeWidth < e.options.zoomWindowWidth ? e.nzWidth : e.options.zoomWindowWidth / e.widthRatio, e.lensStyle = "background-position: 0px 0px;width: " + String(e.options.zoomWindowWidth / e.widthRatio) + "px;height: " + String(e.options.zoomWindowHeight / e.heightRatio) + "px;float: right;display: none;overflow: hidden;z-index: 999;-webkit-transform: translateZ(0);opacity:" + e.options.lensOpacity + ";filter: alpha(opacity = " + 100 * e.options.lensOpacity + "); zoom:1;width:" + lensWidth + "px;height:" + lensHeight + "px;background-color:" + e.options.lensColour + ";cursor:" + e.options.cursor + ";border: " + e.options.lensBorderSize + "px solid " + e.options.lensBorderColour + ";background-repeat: no-repeat;position: absolute;"), e.tintStyle = "display: block;position: absolute;background-color: " + e.options.tintColour + ";filter:alpha(opacity=0);opacity: 0;width: " + e.nzWidth + "px;height: " + e.nzHeight + "px;", e.lensRound = "", "lens" == e.options.zoomType && (e.lensStyle = "background-position: 0px 0px;float: left;display: none;border: " + String(e.options.borderSize) + "px solid " + e.options.borderColour + ";width:" + String(e.options.lensSize) + "px;height:" + String(e.options.lensSize) + "px;background-repeat: no-repeat;position: absolute;"), "round" == e.options.lensShape && (e.lensRound = "border-top-left-radius: " + String(e.options.lensSize / 2 + e.options.borderSize) + "px;border-top-right-radius: " + String(e.options.lensSize / 2 + e.options.borderSize) + "px;border-bottom-left-radius: " + String(e.options.lensSize / 2 + e.options.borderSize) + "px;border-bottom-right-radius: " + String(e.options.lensSize / 2 + e.options.borderSize) + "px;"), e.zoomContainer = t('
    '), t("body").append(e.zoomContainer), e.options.containLensZoom && "lens" == e.options.zoomType && e.zoomContainer.css("overflow", "hidden"), "inner" != e.options.zoomType && (e.zoomLens = t("
     
    ").appendTo(e.zoomContainer).click(function() { e.$elem.trigger("click") }), e.options.tint && (e.tintContainer = t("
    ").addClass("tintContainer"), e.zoomTint = t("
    "), e.zoomLens.wrap(e.tintContainer), e.zoomTintcss = e.zoomLens.after(e.zoomTint), e.zoomTintImage = t('').appendTo(e.zoomLens).click(function() { e.$elem.trigger("click") }))), isNaN(e.options.zoomWindowPosition) ? e.zoomWindow = t("
     
    ").appendTo("body").click(function() { e.$elem.trigger("click") }) : e.zoomWindow = t("
     
    ").appendTo(e.zoomContainer).click(function() { e.$elem.trigger("click") }), e.zoomWindowContainer = t("
    ").addClass("zoomWindowContainer").css("width", e.options.zoomWindowWidth), e.zoomWindow.wrap(e.zoomWindowContainer), "lens" == e.options.zoomType && e.zoomLens.css({ backgroundImage: "url('" + e.imageSrc + "')" }), "window" == e.options.zoomType && e.zoomWindow.css({ backgroundImage: "url('" + e.imageSrc + "')" }), "inner" == e.options.zoomType && e.zoomWindow.css({ backgroundImage: "url('" + e.imageSrc + "')" }), e.$elem.bind("touchmove", function(t) { t.preventDefault(), e.setPosition(t.originalEvent.touches[0] || t.originalEvent.changedTouches[0]) }), e.zoomContainer.bind("touchmove", function(t) { "inner" == e.options.zoomType && e.showHideWindow("show"), t.preventDefault(), e.setPosition(t.originalEvent.touches[0] || t.originalEvent.changedTouches[0]) }), e.zoomContainer.bind("touchend", function(t) { e.showHideWindow("hide"), e.options.showLens && e.showHideLens("hide"), e.options.tint && "inner" != e.options.zoomType && e.showHideTint("hide") }), e.$elem.bind("touchend", function(t) { e.showHideWindow("hide"), e.options.showLens && e.showHideLens("hide"), e.options.tint && "inner" != e.options.zoomType && e.showHideTint("hide") }), e.options.showLens && (e.zoomLens.bind("touchmove", function(t) { t.preventDefault(), e.setPosition(t.originalEvent.touches[0] || t.originalEvent.changedTouches[0]) }), e.zoomLens.bind("touchend", function(t) { e.showHideWindow("hide"), e.options.showLens && e.showHideLens("hide"), e.options.tint && "inner" != e.options.zoomType && e.showHideTint("hide") })), e.$elem.bind("mousemove", function(t) { 0 == e.overWindow && e.setElements("show"), e.lastX === t.clientX && e.lastY === t.clientY || (e.setPosition(t), e.currentLoc = t), e.lastX = t.clientX, e.lastY = t.clientY }), e.zoomContainer.bind("mousemove", function(t) { 0 == e.overWindow && e.setElements("show"), e.lastX === t.clientX && e.lastY === t.clientY || (e.setPosition(t), e.currentLoc = t), e.lastX = t.clientX, e.lastY = t.clientY }), "inner" != e.options.zoomType && e.zoomLens.bind("mousemove", function(t) { e.lastX === t.clientX && e.lastY === t.clientY || (e.setPosition(t), e.currentLoc = t), e.lastX = t.clientX, e.lastY = t.clientY }), e.options.tint && "inner" != e.options.zoomType && e.zoomTint.bind("mousemove", function(t) { e.lastX === t.clientX && e.lastY === t.clientY || (e.setPosition(t), e.currentLoc = t), e.lastX = t.clientX, e.lastY = t.clientY }), "inner" == e.options.zoomType && e.zoomWindow.bind("mousemove", function(t) { e.lastX === t.clientX && e.lastY === t.clientY || (e.setPosition(t), e.currentLoc = t), e.lastX = t.clientX, e.lastY = t.clientY }), e.zoomContainer.add(e.$elem).mouseenter(function() { 0 == e.overWindow && e.setElements("show") }).mouseleave(function() { e.scrollLock || e.setElements("hide") }), "inner" != e.options.zoomType && e.zoomWindow.mouseenter(function() { e.overWindow = !0, e.setElements("hide") }).mouseleave(function() { e.overWindow = !1 }), e.minZoomLevel = e.options.minZoomLevel ? e.options.minZoomLevel : 2 * e.options.scrollZoomIncrement, e.options.scrollZoom && e.zoomContainer.add(e.$elem).bind("mousewheel DOMMouseScroll MozMousePixelScroll", function(o) { e.scrollLock = !0, clearTimeout(t.data(this, "timer")), t.data(this, "timer", setTimeout(function() { e.scrollLock = !1 }, 250)); var i = o.originalEvent.wheelDelta || -1 * o.originalEvent.detail; return o.stopImmediatePropagation(), o.stopPropagation(), o.preventDefault(), 0 < i / 120 ? e.currentZoomLevel >= e.minZoomLevel && e.changeZoomLevel(e.currentZoomLevel - e.options.scrollZoomIncrement) : e.options.maxZoomLevel ? e.currentZoomLevel <= e.options.maxZoomLevel && e.changeZoomLevel(parseFloat(e.currentZoomLevel) + e.options.scrollZoomIncrement) : e.changeZoomLevel(parseFloat(e.currentZoomLevel) + e.options.scrollZoomIncrement), !1 }) }, setElements: function(t) { return !!this.options.zoomEnabled && ("show" == t && this.isWindowSet && ("inner" == this.options.zoomType && this.showHideWindow("show"), "window" == this.options.zoomType && this.showHideWindow("show"), this.options.showLens && this.showHideLens("show"), this.options.tint && "inner" != this.options.zoomType && this.showHideTint("show")), void("hide" == t && ("window" == this.options.zoomType && this.showHideWindow("hide"), this.options.tint || this.showHideWindow("hide"), this.options.showLens && this.showHideLens("hide"), this.options.tint && this.showHideTint("hide")))) }, setPosition: function(t) { return !!this.options.zoomEnabled && (this.nzHeight = this.$elem.height(), this.nzWidth = this.$elem.width(), this.nzOffset = this.$elem.offset(), this.options.tint && "inner" != this.options.zoomType && (this.zoomTint.css({ top: 0 }), this.zoomTint.css({ left: 0 })), this.options.responsive && !this.options.scrollZoom && this.options.showLens && (lensHeight = this.nzHeight < this.options.zoomWindowWidth / this.widthRatio ? this.nzHeight : String(this.options.zoomWindowHeight / this.heightRatio), lensWidth = this.largeWidth < this.options.zoomWindowWidth ? this.nzWidth : this.options.zoomWindowWidth / this.widthRatio, this.widthRatio = this.largeWidth / this.nzWidth, this.heightRatio = this.largeHeight / this.nzHeight, "lens" != this.options.zoomType && (lensHeight = this.nzHeight < this.options.zoomWindowWidth / this.widthRatio ? this.nzHeight : String(this.options.zoomWindowHeight / this.heightRatio), lensWidth = this.options.zoomWindowWidth < this.options.zoomWindowWidth ? this.nzWidth : this.options.zoomWindowWidth / this.widthRatio, this.zoomLens.css("width", lensWidth), this.zoomLens.css("height", lensHeight), this.options.tint && (this.zoomTintImage.css("width", this.nzWidth), this.zoomTintImage.css("height", this.nzHeight))), "lens" == this.options.zoomType && this.zoomLens.css({ width: String(this.options.lensSize) + "px", height: String(this.options.lensSize) + "px" })), this.zoomContainer.css({ top: this.nzOffset.top }), this.zoomContainer.css({ left: this.nzOffset.left }), this.mouseLeft = parseInt(t.pageX - this.nzOffset.left), this.mouseTop = parseInt(t.pageY - this.nzOffset.top), "window" == this.options.zoomType && (this.Etoppos = this.mouseTop < this.zoomLens.height() / 2, this.Eboppos = this.mouseTop > this.nzHeight - this.zoomLens.height() / 2 - 2 * this.options.lensBorderSize, this.Eloppos = this.mouseLeft < 0 + this.zoomLens.width() / 2, this.Eroppos = this.mouseLeft > this.nzWidth - this.zoomLens.width() / 2 - 2 * this.options.lensBorderSize), "inner" == this.options.zoomType && (this.Etoppos = this.mouseTop < this.nzHeight / 2 / this.heightRatio, this.Eboppos = this.mouseTop > this.nzHeight - this.nzHeight / 2 / this.heightRatio, this.Eloppos = this.mouseLeft < 0 + this.nzWidth / 2 / this.widthRatio, this.Eroppos = this.mouseLeft > this.nzWidth - this.nzWidth / 2 / this.widthRatio - 2 * this.options.lensBorderSize), void(0 >= this.mouseLeft || 0 > this.mouseTop || this.mouseLeft > this.nzWidth || this.mouseTop > this.nzHeight ? this.setElements("hide") : (this.options.showLens && (this.lensLeftPos = String(this.mouseLeft - this.zoomLens.width() / 2), this.lensTopPos = String(this.mouseTop - this.zoomLens.height() / 2)), this.Etoppos && (this.lensTopPos = 0), this.Eloppos && (this.tintpos = this.lensLeftPos = this.windowLeftPos = 0), "window" == this.options.zoomType && (this.Eboppos && (this.lensTopPos = Math.max(this.nzHeight - this.zoomLens.height() - 2 * this.options.lensBorderSize, 0)), this.Eroppos && (this.lensLeftPos = this.nzWidth - this.zoomLens.width() - 2 * this.options.lensBorderSize)), "inner" == this.options.zoomType && (this.Eboppos && (this.lensTopPos = Math.max(this.nzHeight - 2 * this.options.lensBorderSize, 0)), this.Eroppos && (this.lensLeftPos = this.nzWidth - this.nzWidth - 2 * this.options.lensBorderSize)), "lens" == this.options.zoomType && (this.windowLeftPos = String(-1 * ((t.pageX - this.nzOffset.left) * this.widthRatio - this.zoomLens.width() / 2)), this.windowTopPos = String(-1 * ((t.pageY - this.nzOffset.top) * this.heightRatio - this.zoomLens.height() / 2)), this.zoomLens.css({ backgroundPosition: this.windowLeftPos + "px " + this.windowTopPos + "px" }), this.changeBgSize && (this.nzHeight > this.nzWidth ? ("lens" == this.options.zoomType && this.zoomLens.css({ "background-size": this.largeWidth / this.newvalueheight + "px " + this.largeHeight / this.newvalueheight + "px" }), this.zoomWindow.css({ "background-size": this.largeWidth / this.newvalueheight + "px " + this.largeHeight / this.newvalueheight + "px" })) : ("lens" == this.options.zoomType && this.zoomLens.css({ "background-size": this.largeWidth / this.newvaluewidth + "px " + this.largeHeight / this.newvaluewidth + "px" }), this.zoomWindow.css({ "background-size": this.largeWidth / this.newvaluewidth + "px " + this.largeHeight / this.newvaluewidth + "px" })), this.changeBgSize = !1), this.setWindowPostition(t)), this.options.tint && "inner" != this.options.zoomType && this.setTintPosition(t), "window" == this.options.zoomType && this.setWindowPostition(t), "inner" == this.options.zoomType && this.setWindowPostition(t), this.options.showLens && (this.fullwidth && "lens" != this.options.zoomType && (this.lensLeftPos = 0), this.zoomLens.css({ left: this.lensLeftPos + "px", top: this.lensTopPos + "px" }))))) }, showHideWindow: function(t) { "show" != t || this.isWindowActive || (this.options.zoomWindowFadeIn ? this.zoomWindow.stop(!0, !0, !1).fadeIn(this.options.zoomWindowFadeIn) : this.zoomWindow.show(), this.isWindowActive = !0), "hide" == t && this.isWindowActive && (this.options.zoomWindowFadeOut ? this.zoomWindow.stop(!0, !0).fadeOut(this.options.zoomWindowFadeOut) : this.zoomWindow.hide(), this.isWindowActive = !1) }, showHideLens: function(t) { "show" != t || this.isLensActive || (this.options.lensFadeIn ? this.zoomLens.stop(!0, !0, !1).fadeIn(this.options.lensFadeIn) : this.zoomLens.show(), this.isLensActive = !0), "hide" == t && this.isLensActive && (this.options.lensFadeOut ? this.zoomLens.stop(!0, !0).fadeOut(this.options.lensFadeOut) : this.zoomLens.hide(), this.isLensActive = !1) }, showHideTint: function(t) { "show" != t || this.isTintActive || (this.options.zoomTintFadeIn ? this.zoomTint.css({ opacity: this.options.tintOpacity }).animate().stop(!0, !0).fadeIn("slow") : (this.zoomTint.css({ opacity: this.options.tintOpacity }).animate(), this.zoomTint.show()), this.isTintActive = !0), "hide" == t && this.isTintActive && (this.options.zoomTintFadeOut ? this.zoomTint.stop(!0, !0).fadeOut(this.options.zoomTintFadeOut) : this.zoomTint.hide(), this.isTintActive = !1) }, setLensPostition: function(t) {}, setWindowPostition: function(e) { var o = this; if (isNaN(o.options.zoomWindowPosition)) o.externalContainer = t("#" + o.options.zoomWindowPosition), o.externalContainerWidth = o.externalContainer.width(), o.externalContainerHeight = o.externalContainer.height(), o.externalContainerOffset = o.externalContainer.offset(), o.windowOffsetTop = o.externalContainerOffset.top, o.windowOffsetLeft = o.externalContainerOffset.left; else switch (o.options.zoomWindowPosition) { case 1: o.windowOffsetTop = o.options.zoomWindowOffety, o.windowOffsetLeft = +o.nzWidth; break; case 2: o.options.zoomWindowHeight > o.nzHeight && (o.windowOffsetTop = -1 * (o.options.zoomWindowHeight / 2 - o.nzHeight / 2), o.windowOffsetLeft = o.nzWidth); break; case 3: o.windowOffsetTop = o.nzHeight - o.zoomWindow.height() - 2 * o.options.borderSize, o.windowOffsetLeft = o.nzWidth; break; case 4: o.windowOffsetTop = o.nzHeight, o.windowOffsetLeft = o.nzWidth; break; case 5: o.windowOffsetTop = o.nzHeight, o.windowOffsetLeft = o.nzWidth - o.zoomWindow.width() - 2 * o.options.borderSize; break; case 6: o.options.zoomWindowHeight > o.nzHeight && (o.windowOffsetTop = o.nzHeight, o.windowOffsetLeft = -1 * (o.options.zoomWindowWidth / 2 - o.nzWidth / 2 + 2 * o.options.borderSize)); break; case 7: o.windowOffsetTop = o.nzHeight, o.windowOffsetLeft = 0; break; case 8: o.windowOffsetTop = o.nzHeight, o.windowOffsetLeft = -1 * (o.zoomWindow.width() + 2 * o.options.borderSize); break; case 9: o.windowOffsetTop = o.nzHeight - o.zoomWindow.height() - 2 * o.options.borderSize, o.windowOffsetLeft = -1 * (o.zoomWindow.width() + 2 * o.options.borderSize); break; case 10: o.options.zoomWindowHeight > o.nzHeight && (o.windowOffsetTop = -1 * (o.options.zoomWindowHeight / 2 - o.nzHeight / 2), o.windowOffsetLeft = -1 * (o.zoomWindow.width() + 2 * o.options.borderSize)); break; case 11: o.windowOffsetTop = o.options.zoomWindowOffety, o.windowOffsetLeft = -1 * (o.zoomWindow.width() + 2 * o.options.borderSize); break; case 12: o.windowOffsetTop = -1 * (o.zoomWindow.height() + 2 * o.options.borderSize), o.windowOffsetLeft = -1 * (o.zoomWindow.width() + 2 * o.options.borderSize); break; case 13: o.windowOffsetTop = -1 * (o.zoomWindow.height() + 2 * o.options.borderSize), o.windowOffsetLeft = 0; break; case 14: o.options.zoomWindowHeight > o.nzHeight && (o.windowOffsetTop = -1 * (o.zoomWindow.height() + 2 * o.options.borderSize), o.windowOffsetLeft = -1 * (o.options.zoomWindowWidth / 2 - o.nzWidth / 2 + 2 * o.options.borderSize)); break; case 15: o.windowOffsetTop = -1 * (o.zoomWindow.height() + 2 * o.options.borderSize), o.windowOffsetLeft = o.nzWidth - o.zoomWindow.width() - 2 * o.options.borderSize; break; case 16: o.windowOffsetTop = -1 * (o.zoomWindow.height() + 2 * o.options.borderSize), o.windowOffsetLeft = o.nzWidth; break; default: o.windowOffsetTop = o.options.zoomWindowOffety, o.windowOffsetLeft = o.nzWidth } o.isWindowSet = !0, o.windowOffsetTop += o.options.zoomWindowOffety, o.windowOffsetLeft += o.options.zoomWindowOffetx, o.zoomWindow.css({ top: o.windowOffsetTop }), o.zoomWindow.css({ left: o.windowOffsetLeft }), "inner" == o.options.zoomType && (o.zoomWindow.css({ top: 0 }), o.zoomWindow.css({ left: 0 })), o.windowLeftPos = String(-1 * ((e.pageX - o.nzOffset.left) * o.widthRatio - o.zoomWindow.width() / 2)), o.windowTopPos = String(-1 * ((e.pageY - o.nzOffset.top) * o.heightRatio - o.zoomWindow.height() / 2)), o.Etoppos && (o.windowTopPos = 0), o.Eloppos && (o.windowLeftPos = 0), o.Eboppos && (o.windowTopPos = -1 * (o.largeHeight / o.currentZoomLevel - o.zoomWindow.height())), o.Eroppos && (o.windowLeftPos = -1 * (o.largeWidth / o.currentZoomLevel - o.zoomWindow.width())), o.fullheight && (o.windowTopPos = 0), o.fullwidth && (o.windowLeftPos = 0), "window" != o.options.zoomType && "inner" != o.options.zoomType || (1 == o.zoomLock && (1 >= o.widthRatio && (o.windowLeftPos = 0), 1 >= o.heightRatio && (o.windowTopPos = 0)), o.largeHeight < o.options.zoomWindowHeight && (o.windowTopPos = 0), o.largeWidth < o.options.zoomWindowWidth && (o.windowLeftPos = 0), o.options.easing ? (o.xp || (o.xp = 0), o.yp || (o.yp = 0), o.loop || (o.loop = setInterval(function() { o.xp += (o.windowLeftPos - o.xp) / o.options.easingAmount, o.yp += (o.windowTopPos - o.yp) / o.options.easingAmount, o.scrollingLock ? (clearInterval(o.loop), o.xp = o.windowLeftPos, o.yp = o.windowTopPos, o.xp = -1 * ((e.pageX - o.nzOffset.left) * o.widthRatio - o.zoomWindow.width() / 2), o.yp = -1 * ((e.pageY - o.nzOffset.top) * o.heightRatio - o.zoomWindow.height() / 2), o.changeBgSize && (o.nzHeight > o.nzWidth ? ("lens" == o.options.zoomType && o.zoomLens.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" }), o.zoomWindow.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" })) : ("lens" != o.options.zoomType && o.zoomLens.css({ "background-size": o.largeWidth / o.newvaluewidth + "px " + o.largeHeight / o.newvalueheight + "px" }), o.zoomWindow.css({ "background-size": o.largeWidth / o.newvaluewidth + "px " + o.largeHeight / o.newvaluewidth + "px" })), o.changeBgSize = !1), o.zoomWindow.css({ backgroundPosition: o.windowLeftPos + "px " + o.windowTopPos + "px" }), o.scrollingLock = !1, o.loop = !1) : (o.changeBgSize && (o.nzHeight > o.nzWidth ? ("lens" == o.options.zoomType && o.zoomLens.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" }), o.zoomWindow.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" })) : ("lens" != o.options.zoomType && o.zoomLens.css({ "background-size": o.largeWidth / o.newvaluewidth + "px " + o.largeHeight / o.newvaluewidth + "px" }), o.zoomWindow.css({ "background-size": o.largeWidth / o.newvaluewidth + "px " + o.largeHeight / o.newvaluewidth + "px" })), o.changeBgSize = !1), o.zoomWindow.css({ backgroundPosition: o.xp + "px " + o.yp + "px" })) }, 16))) : (o.changeBgSize && (o.nzHeight > o.nzWidth ? ("lens" == o.options.zoomType && o.zoomLens.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" }), o.zoomWindow.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" })) : ("lens" == o.options.zoomType && o.zoomLens.css({ "background-size": o.largeWidth / o.newvaluewidth + "px " + o.largeHeight / o.newvaluewidth + "px" }), o.largeHeight / o.newvaluewidth < o.options.zoomWindowHeight ? o.zoomWindow.css({ "background-size": o.largeWidth / o.newvaluewidth + "px " + o.largeHeight / o.newvaluewidth + "px" }) : o.zoomWindow.css({ "background-size": o.largeWidth / o.newvalueheight + "px " + o.largeHeight / o.newvalueheight + "px" })), o.changeBgSize = !1), o.zoomWindow.css({ backgroundPosition: o.windowLeftPos + "px " + o.windowTopPos + "px" }))) }, setTintPosition: function(t) { this.nzOffset = this.$elem.offset(), this.tintpos = String(-1 * (t.pageX - this.nzOffset.left - this.zoomLens.width() / 2)), this.tintposy = String(-1 * (t.pageY - this.nzOffset.top - this.zoomLens.height() / 2)), this.Etoppos && (this.tintposy = 0), this.Eloppos && (this.tintpos = 0), this.Eboppos && (this.tintposy = -1 * (this.nzHeight - this.zoomLens.height() - 2 * this.options.lensBorderSize)), this.Eroppos && (this.tintpos = -1 * (this.nzWidth - this.zoomLens.width() - 2 * this.options.lensBorderSize)), this.options.tint && (this.fullheight && (this.tintposy = 0), this.fullwidth && (this.tintpos = 0), this.zoomTintImage.css({ left: this.tintpos + "px" }), this.zoomTintImage.css({ top: this.tintposy + "px" })) }, swaptheimage: function(e, o) { var i = this, n = new Image; i.options.loadingIcon && (i.spinner = t("
    '), i.$elem.after(i.spinner)), i.options.onImageSwap(i.$elem), n.onload = function() { i.largeWidth = n.width, i.largeHeight = n.height, i.zoomImage = o, i.zoomWindow.css({ "background-size": i.largeWidth + "px " + i.largeHeight + "px" }), i.zoomWindow.css({ "background-size": i.largeWidth + "px " + i.largeHeight + "px" }), i.swapAction(e, o) }, n.src = o }, swapAction: function(e, o) { var i = this, n = new Image; if (n.onload = function() { i.nzHeight = n.height, i.nzWidth = n.width, i.options.onImageSwapComplete(i.$elem), i.doneCallback() }, n.src = e, i.currentZoomLevel = i.options.zoomLevel, i.options.maxZoomLevel = !1, "lens" == i.options.zoomType && i.zoomLens.css({ backgroundImage: "url('" + o + "')" }), "window" == i.options.zoomType && i.zoomWindow.css({ backgroundImage: "url('" + o + "')" }), "inner" == i.options.zoomType && i.zoomWindow.css({ backgroundImage: "url('" + o + "')" }), i.currentImage = o, i.options.imageCrossfade) { var s = i.$elem, r = s.clone(); i.$elem.attr("src", e), i.$elem.after(r), r.stop(!0).fadeOut(i.options.imageCrossfade, function() { t(this).remove() }), i.$elem.width("auto").removeAttr("width"), i.$elem.height("auto").removeAttr("height"), s.fadeIn(i.options.imageCrossfade), i.options.tint && "inner" != i.options.zoomType && (s = i.zoomTintImage, r = s.clone(), i.zoomTintImage.attr("src", o), i.zoomTintImage.after(r), r.stop(!0).fadeOut(i.options.imageCrossfade, function() { t(this).remove() }), s.fadeIn(i.options.imageCrossfade), i.zoomTint.css({ height: i.$elem.height() }), i.zoomTint.css({ width: i.$elem.width() })), i.zoomContainer.css("height", i.$elem.height()), i.zoomContainer.css("width", i.$elem.width()), "inner" != i.options.zoomType || i.options.constrainType || (i.zoomWrap.parent().css("height", i.$elem.height()), i.zoomWrap.parent().css("width", i.$elem.width()), i.zoomWindow.css("height", i.$elem.height()), i.zoomWindow.css("width", i.$elem.width())) } else i.$elem.attr("src", e), i.options.tint && (i.zoomTintImage.attr("src", o), i.zoomTintImage.attr("height", i.$elem.height()), i.zoomTintImage.css({ height: i.$elem.height() }), i.zoomTint.css({ height: i.$elem.height() })), i.zoomContainer.css("height", i.$elem.height()), i.zoomContainer.css("width", i.$elem.width()); i.options.imageCrossfade && (i.zoomWrap.css("height", i.$elem.height()), i.zoomWrap.css("width", i.$elem.width())), i.options.constrainType && ("height" == i.options.constrainType && (i.zoomContainer.css("height", i.options.constrainSize), i.zoomContainer.css("width", "auto"), i.options.imageCrossfade ? (i.zoomWrap.css("height", i.options.constrainSize), i.zoomWrap.css("width", "auto"), i.constwidth = i.zoomWrap.width()) : (i.$elem.css("height", i.options.constrainSize), i.$elem.css("width", "auto"), i.constwidth = i.$elem.width()), "inner" == i.options.zoomType && (i.zoomWrap.parent().css("height", i.options.constrainSize), i.zoomWrap.parent().css("width", i.constwidth), i.zoomWindow.css("height", i.options.constrainSize), i.zoomWindow.css("width", i.constwidth)), i.options.tint && (i.tintContainer.css("height", i.options.constrainSize), i.tintContainer.css("width", i.constwidth), i.zoomTint.css("height", i.options.constrainSize), i.zoomTint.css("width", i.constwidth), i.zoomTintImage.css("height", i.options.constrainSize), i.zoomTintImage.css("width", i.constwidth))), "width" == i.options.constrainType && (i.zoomContainer.css("height", "auto"), i.zoomContainer.css("width", i.options.constrainSize), i.options.imageCrossfade ? (i.zoomWrap.css("height", "auto"), i.zoomWrap.css("width", i.options.constrainSize), i.constheight = i.zoomWrap.height()) : (i.$elem.css("height", "auto"), i.$elem.css("width", i.options.constrainSize), i.constheight = i.$elem.height()), "inner" == i.options.zoomType && (i.zoomWrap.parent().css("height", i.constheight), i.zoomWrap.parent().css("width", i.options.constrainSize), i.zoomWindow.css("height", i.constheight), i.zoomWindow.css("width", i.options.constrainSize)), i.options.tint && (i.tintContainer.css("height", i.constheight), i.tintContainer.css("width", i.options.constrainSize), i.zoomTint.css("height", i.constheight), i.zoomTint.css("width", i.options.constrainSize), i.zoomTintImage.css("height", i.constheight), i.zoomTintImage.css("width", i.options.constrainSize)))) }, doneCallback: function() { this.options.loadingIcon && this.spinner.hide(), this.nzOffset = this.$elem.offset(), this.nzWidth = this.$elem.width(), this.nzHeight = this.$elem.height(), this.currentZoomLevel = this.options.zoomLevel, this.widthRatio = this.largeWidth / this.nzWidth, this.heightRatio = this.largeHeight / this.nzHeight, "window" == this.options.zoomType && (lensHeight = this.nzHeight < this.options.zoomWindowWidth / this.widthRatio ? this.nzHeight : String(this.options.zoomWindowHeight / this.heightRatio), lensWidth = this.options.zoomWindowWidth < this.options.zoomWindowWidth ? this.nzWidth : this.options.zoomWindowWidth / this.widthRatio, this.zoomLens && (this.zoomLens.css("width", lensWidth), this.zoomLens.css("height", lensHeight))) }, getCurrentImage: function() { return this.zoomImage }, getGalleryList: function() { var e = this; return e.gallerylist = [], e.options.gallery ? t("#" + e.options.gallery + " a").each(function() { var o = ""; t(this).data("zoom-image") ? o = t(this).data("zoom-image") : t(this).data("image") && (o = t(this).data("image")), o == e.zoomImage ? e.gallerylist.unshift({ href: "" + o, title: t(this).find("img").attr("title") }) : e.gallerylist.push({ href: "" + o, title: t(this).find("img").attr("title") }) }) : e.gallerylist.push({ href: "" + e.zoomImage, title: t(this).find("img").attr("title") }), e.gallerylist }, changeZoomLevel: function(t) { this.scrollingLock = !0, this.newvalue = parseFloat(t).toFixed(2), newvalue = parseFloat(t).toFixed(2), maxheightnewvalue = this.largeHeight / (this.options.zoomWindowHeight / this.nzHeight * this.nzHeight), maxwidthtnewvalue = this.largeWidth / (this.options.zoomWindowWidth / this.nzWidth * this.nzWidth), "inner" != this.options.zoomType && (maxheightnewvalue <= newvalue ? (this.heightRatio = this.largeHeight / maxheightnewvalue / this.nzHeight, this.newvalueheight = maxheightnewvalue, this.fullheight = !0) : (this.heightRatio = this.largeHeight / newvalue / this.nzHeight, this.newvalueheight = newvalue, this.fullheight = !1), maxwidthtnewvalue <= newvalue ? (this.widthRatio = this.largeWidth / maxwidthtnewvalue / this.nzWidth, this.newvaluewidth = maxwidthtnewvalue, this.fullwidth = !0) : (this.widthRatio = this.largeWidth / newvalue / this.nzWidth, this.newvaluewidth = newvalue, this.fullwidth = !1), "lens" == this.options.zoomType && (maxheightnewvalue <= newvalue ? (this.fullwidth = !0, this.newvaluewidth = maxheightnewvalue) : (this.widthRatio = this.largeWidth / newvalue / this.nzWidth, this.newvaluewidth = newvalue, this.fullwidth = !1))), "inner" == this.options.zoomType && (maxheightnewvalue = parseFloat(this.largeHeight / this.nzHeight).toFixed(2), maxwidthtnewvalue = parseFloat(this.largeWidth / this.nzWidth).toFixed(2), newvalue > maxheightnewvalue && (newvalue = maxheightnewvalue), newvalue > maxwidthtnewvalue && (newvalue = maxwidthtnewvalue), maxheightnewvalue <= newvalue ? (this.heightRatio = this.largeHeight / newvalue / this.nzHeight, this.newvalueheight = newvalue > maxheightnewvalue ? maxheightnewvalue : newvalue, this.fullheight = !0) : (this.heightRatio = this.largeHeight / newvalue / this.nzHeight, this.newvalueheight = newvalue > maxheightnewvalue ? maxheightnewvalue : newvalue, this.fullheight = !1), maxwidthtnewvalue <= newvalue ? (this.widthRatio = this.largeWidth / newvalue / this.nzWidth, this.newvaluewidth = newvalue > maxwidthtnewvalue ? maxwidthtnewvalue : newvalue, this.fullwidth = !0) : (this.widthRatio = this.largeWidth / newvalue / this.nzWidth, this.newvaluewidth = newvalue, this.fullwidth = !1)), scrcontinue = !1, "inner" == this.options.zoomType && (this.nzWidth > this.nzHeight && (this.newvaluewidth <= maxwidthtnewvalue ? scrcontinue = !0 : (scrcontinue = !1, this.fullwidth = this.fullheight = !0)), this.nzHeight > this.nzWidth && (this.newvaluewidth <= maxwidthtnewvalue ? scrcontinue = !0 : (scrcontinue = !1, this.fullwidth = this.fullheight = !0))), "inner" != this.options.zoomType && (scrcontinue = !0), scrcontinue && (this.zoomLock = 0, this.changeZoom = !0, this.options.zoomWindowHeight / this.heightRatio <= this.nzHeight && (this.currentZoomLevel = this.newvalueheight, "lens" != this.options.zoomType && "inner" != this.options.zoomType && (this.changeBgSize = !0, this.zoomLens.css({ height: String(this.options.zoomWindowHeight / this.heightRatio) + "px" })), "lens" == this.options.zoomType || "inner" == this.options.zoomType) && (this.changeBgSize = !0), this.options.zoomWindowWidth / this.widthRatio <= this.nzWidth && ("inner" != this.options.zoomType && this.newvaluewidth > this.newvalueheight && (this.currentZoomLevel = this.newvaluewidth), "lens" != this.options.zoomType && "inner" != this.options.zoomType && (this.changeBgSize = !0, this.zoomLens.css({ width: String(this.options.zoomWindowWidth / this.widthRatio) + "px" })), "lens" == this.options.zoomType || "inner" == this.options.zoomType) && (this.changeBgSize = !0), "inner" == this.options.zoomType && (this.changeBgSize = !0, this.nzWidth > this.nzHeight && (this.currentZoomLevel = this.newvaluewidth), this.nzHeight > this.nzWidth && (this.currentZoomLevel = this.newvaluewidth))), this.setPosition(this.currentLoc) }, closeAll: function() { self.zoomWindow && self.zoomWindow.hide(), self.zoomLens && self.zoomLens.hide(), self.zoomTint && self.zoomTint.hide() }, changeState: function(t) { "enable" == t && (this.options.zoomEnabled = !0), "disable" == t && (this.options.zoomEnabled = !1) } }; t.fn.elevateZoom = function(e) { return this.each(function() { var o = Object.create(n); o.init(e, this), t.data(this, "elevateZoom", o) }) }, t.fn.elevateZoom.options = { zoomActivation: "hover", zoomEnabled: !0, preloading: 1, zoomLevel: 1, scrollZoom: !1, scrollZoomIncrement: .1, minZoomLevel: !1, maxZoomLevel: !1, easing: !1, easingAmount: 12, lensSize: 200, zoomWindowWidth: 400, zoomWindowHeight: 400, zoomWindowOffetx: 0, zoomWindowOffety: 0, zoomWindowPosition: 1, zoomWindowBgColour: "#fff", lensFadeIn: !1, lensFadeOut: !1, debug: !1, zoomWindowFadeIn: !1, zoomWindowFadeOut: !1, zoomWindowAlwaysShow: !1, zoomTintFadeIn: !1, zoomTintFadeOut: !1, borderSize: 4, showLens: !0, borderColour: "#888", lensBorderSize: 1, lensBorderColour: "#000", lensShape: "square", zoomType: "window", containLensZoom: !1, lensColour: "white", lensOpacity: .4, lenszoom: !1, tint: !1, tintColour: "#333", tintOpacity: .4, gallery: !1, galleryActiveClass: "zoomGalleryActive", imageCrossfade: !1, constrainType: !1, constrainSize: !1, loadingIcon: !1, cursor: "default", responsive: !0, onComplete: t.noop, onZoomedImageLoaded: function() {}, onImageSwap: t.noop, onImageSwapComplete: t.noop } }(jQuery, window, document), function(t) { "function" == typeof define && define.amd ? define(["jquery"], t) : t("object" == typeof exports ? require("jquery") : window.jQuery || window.Zepto) }(function(t) { var e, o, i, n, s, r, a = "Close", l = "BeforeClose", h = "AfterClose", d = "BeforeAppend", c = "MarkupParse", p = "Open", u = "Change", f = "mfp", m = "." + f, g = "mfp-ready", v = "mfp-removing", y = "mfp-prevent-close", w = function() {}, b = !!window.jQuery, z = t(window), T = function(t, o) { e.ev.on(f + t + m, o) }, x = function(e, o, i, n) { var s = document.createElement("div"); return s.className = "mfp-" + e, i && (s.innerHTML = i), n ? o && o.appendChild(s) : (s = t(s), o && s.appendTo(o)), s }, k = function(o, i) { e.ev.triggerHandler(f + o, i), e.st.callbacks && (o = o.charAt(0).toLowerCase() + o.slice(1), e.st.callbacks[o] && e.st.callbacks[o].apply(e, t.isArray(i) ? i : [i])) }, C = function(o) { return o === r && e.currTemplate.closeBtn || (e.currTemplate.closeBtn = t(e.st.closeMarkup.replace("%title%", e.st.tClose)), r = o), e.currTemplate.closeBtn }, L = function() { t.magnificPopup.instance || (e = new w, e.init(), t.magnificPopup.instance = e) }, S = function() { var t = document.createElement("p").style, e = ["ms", "O", "Moz", "Webkit"]; if (void 0 !== t.transition) return !0; for (; e.length;) if (e.pop() + "Transition" in t) return !0; return !1 }; w.prototype = { constructor: w, init: function() { var o = navigator.appVersion; e.isLowIE = e.isIE8 = document.all && !document.addEventListener, e.isAndroid = /android/gi.test(o), e.isIOS = /iphone|ipad|ipod/gi.test(o), e.supportsTransition = S(), e.probablyMobile = e.isAndroid || e.isIOS || /(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent), i = t(document), e.popupsCache = {} }, open: function(o) { var n; if (o.isObj === !1) { e.items = o.items.toArray(), e.index = 0; var r, a = o.items; for (n = 0; n < a.length; n++) if (r = a[n], r.parsed && (r = r.el[0]), r === o.el[0]) { e.index = n; break } } else e.items = t.isArray(o.items) ? o.items : [o.items], e.index = o.index || 0; if (e.isOpen) return void e.updateItemHTML(); e.types = [], s = "", o.mainEl && o.mainEl.length ? e.ev = o.mainEl.eq(0) : e.ev = i, o.key ? (e.popupsCache[o.key] || (e.popupsCache[o.key] = {}), e.currTemplate = e.popupsCache[o.key]) : e.currTemplate = {}, e.st = t.extend(!0, {}, t.magnificPopup.defaults, o), e.fixedContentPos = "auto" === e.st.fixedContentPos ? !e.probablyMobile : e.st.fixedContentPos, e.st.modal && (e.st.closeOnContentClick = !1, e.st.closeOnBgClick = !1, e.st.showCloseBtn = !1, e.st.enableEscapeKey = !1), e.bgOverlay || (e.bgOverlay = x("bg").on("click" + m, function() { e.close() }), e.wrap = x("wrap").attr("tabindex", -1).on("click" + m, function(t) { e._checkIfClose(t.target) && e.close() }), e.container = x("container", e.wrap)), e.contentContainer = x("content"), e.st.preloader && (e.preloader = x("preloader", e.container, e.st.tLoading)); var l = t.magnificPopup.modules; for (n = 0; n < l.length; n++) { var h = l[n]; h = h.charAt(0).toUpperCase() + h.slice(1), e["init" + h].call(e) } k("BeforeOpen"), e.st.showCloseBtn && (e.st.closeBtnInside ? (T(c, function(t, e, o, i) { o.close_replaceWith = C(i.type) }), s += " mfp-close-btn-in") : e.wrap.append(C())), e.st.alignTop && (s += " mfp-align-top"), e.fixedContentPos ? e.wrap.css({ overflow: e.st.overflowY, overflowX: "hidden", overflowY: e.st.overflowY }) : e.wrap.css({ top: z.scrollTop(), position: "absolute" }), (e.st.fixedBgPos === !1 || "auto" === e.st.fixedBgPos && !e.fixedContentPos) && e.bgOverlay.css({ height: i.height(), position: "absolute" }), e.st.enableEscapeKey && i.on("keyup" + m, function(t) { 27 === t.keyCode && e.close() }), z.on("resize" + m, function() { e.updateSize() }), e.st.closeOnContentClick || (s += " mfp-auto-cursor"), s && e.wrap.addClass(s); var d = e.wH = z.height(), u = {}; if (e.fixedContentPos && e._hasScrollBar(d)) { var f = e._getScrollbarSize(); f && (u.marginRight = f) } e.fixedContentPos && (e.isIE7 ? t("body, html").css("overflow", "hidden") : u.overflow = "hidden"); var v = e.st.mainClass; return e.isIE7 && (v += " mfp-ie7"), v && e._addClassToMFP(v), e.updateItemHTML(), k("BuildControls"), t("html").css(u), e.bgOverlay.add(e.wrap).prependTo(e.st.prependTo || t(document.body)), e._lastFocusedEl = document.activeElement, setTimeout(function() { e.content ? (e._addClassToMFP(g), e._setFocus()) : e.bgOverlay.addClass(g), i.on("focusin" + m, e._onFocusIn) }, 16), e.isOpen = !0, e.updateSize(d), k(p), o }, close: function() { e.isOpen && (k(l), e.isOpen = !1, e.st.removalDelay && !e.isLowIE && e.supportsTransition ? (e._addClassToMFP(v), setTimeout(function() { e._close() }, e.st.removalDelay)) : e._close()) }, _close: function() { k(a); var o = v + " " + g + " "; if (e.bgOverlay.detach(), e.wrap.detach(), e.container.empty(), e.st.mainClass && (o += e.st.mainClass + " "), e._removeClassFromMFP(o), e.fixedContentPos) { var n = { marginRight: "" }; e.isIE7 ? t("body, html").css("overflow", "") : n.overflow = "", t("html").css(n) } i.off("keyup" + m + " focusin" + m), e.ev.off(m), e.wrap.attr("class", "mfp-wrap").removeAttr("style"), e.bgOverlay.attr("class", "mfp-bg"), e.container.attr("class", "mfp-container"), !e.st.showCloseBtn || e.st.closeBtnInside && e.currTemplate[e.currItem.type] !== !0 || e.currTemplate.closeBtn && e.currTemplate.closeBtn.detach(), e.st.autoFocusLast && e._lastFocusedEl && t(e._lastFocusedEl).focus(), e.currItem = null, e.content = null, e.currTemplate = null, e.prevHeight = 0, k(h) }, updateSize: function(t) { if (e.isIOS) { var o = document.documentElement.clientWidth / window.innerWidth, i = window.innerHeight * o; e.wrap.css("height", i), e.wH = i } else e.wH = t || z.height(); e.fixedContentPos || e.wrap.css("height", e.wH), k("Resize") }, updateItemHTML: function() { var o = e.items[e.index]; e.contentContainer.detach(), e.content && e.content.detach(), o.parsed || (o = e.parseEl(e.index)); var i = o.type; if (k("BeforeChange", [e.currItem ? e.currItem.type : "", i]), e.currItem = o, !e.currTemplate[i]) { var s = !!e.st[i] && e.st[i].markup; k("FirstMarkupParse", s), s ? e.currTemplate[i] = t(s) : e.currTemplate[i] = !0 } n && n !== o.type && e.container.removeClass("mfp-" + n + "-holder"); var r = e["get" + i.charAt(0).toUpperCase() + i.slice(1)](o, e.currTemplate[i]); e.appendContent(r, i), o.preloaded = !0, k(u, o), n = o.type, e.container.prepend(e.contentContainer), k("AfterChange") }, appendContent: function(t, o) { e.content = t, t ? e.st.showCloseBtn && e.st.closeBtnInside && e.currTemplate[o] === !0 ? e.content.find(".mfp-close").length || e.content.append(C()) : e.content = t : e.content = "", k(d), e.container.addClass("mfp-" + o + "-holder"), e.contentContainer.append(e.content) }, parseEl: function(o) { var i, n = e.items[o]; if (n.tagName ? n = { el: t(n) } : (i = n.type, n = { data: n, src: n.src }), n.el) { for (var s = e.types, r = 0; r < s.length; r++) if (n.el.hasClass("mfp-" + s[r])) { i = s[r]; break } n.src = n.el.attr("data-mfp-src"), n.src || (n.src = n.el.attr("href")) } return n.type = i || e.st.type || "inline", n.index = o, n.parsed = !0, e.items[o] = n, k("ElementParse", n), e.items[o] }, addGroup: function(t, o) { var i = function(i) { i.mfpEl = this, e._openClick(i, t, o) }; o || (o = {}); var n = "click.magnificPopup"; o.mainEl = t, o.items ? (o.isObj = !0, t.off(n).on(n, i)) : (o.isObj = !1, o.delegate ? t.off(n).on(n, o.delegate, i) : (o.items = t, t.off(n).on(n, i))) }, _openClick: function(o, i, n) { var s = void 0 !== n.midClick ? n.midClick : t.magnificPopup.defaults.midClick; if (s || !(2 === o.which || o.ctrlKey || o.metaKey || o.altKey || o.shiftKey)) { var r = void 0 !== n.disableOn ? n.disableOn : t.magnificPopup.defaults.disableOn; if (r) if (t.isFunction(r)) { if (!r.call(e)) return !0 } else if (z.width() < r) return !0; o.type && (o.preventDefault(), e.isOpen && o.stopPropagation()), n.el = t(o.mfpEl), n.delegate && (n.items = i.find(n.delegate)), e.open(n) } }, updateStatus: function(t, i) { if (e.preloader) { o !== t && e.container.removeClass("mfp-s-" + o), i || "loading" !== t || (i = e.st.tLoading); var n = { status: t, text: i }; k("UpdateStatus", n), t = n.status, i = n.text, e.preloader.html(i), e.preloader.find("a").on("click", function(t) { t.stopImmediatePropagation() }), e.container.addClass("mfp-s-" + t), o = t } }, _checkIfClose: function(o) { if (!t(o).hasClass(y)) { var i = e.st.closeOnContentClick, n = e.st.closeOnBgClick; if (i && n) return !0; if (!e.content || t(o).hasClass("mfp-close") || e.preloader && o === e.preloader[0]) return !0; if (o === e.content[0] || t.contains(e.content[0], o)) { if (i) return !0 } else if (n && t.contains(document, o)) return !0; return !1 } }, _addClassToMFP: function(t) { e.bgOverlay.addClass(t), e.wrap.addClass(t) }, _removeClassFromMFP: function(t) { this.bgOverlay.removeClass(t), e.wrap.removeClass(t) }, _hasScrollBar: function(t) { return (e.isIE7 ? i.height() : document.body.scrollHeight) > (t || z.height()) }, _setFocus: function() { (e.st.focus ? e.content.find(e.st.focus).eq(0) : e.wrap).focus() }, _onFocusIn: function(o) { if (o.target !== e.wrap[0] && !t.contains(e.wrap[0], o.target)) return e._setFocus(), !1 }, _parseMarkup: function(e, o, i) { var n; i.data && (o = t.extend(i.data, o)), k(c, [e, o, i]), t.each(o, function(o, i) { if (void 0 === i || i === !1) return !0; if (n = o.split("_"), n.length > 1) { var s = e.find(m + "-" + n[0]); if (s.length > 0) { var r = n[1]; "replaceWith" === r ? s[0] !== i[0] && s.replaceWith(i) : "img" === r ? s.is("img") ? s.attr("src", i) : s.replaceWith(t("").attr("src", i).attr("class", s.attr("class"))) : s.attr(n[1], i) } } else e.find(m + "-" + o).html(i) }) }, _getScrollbarSize: function() { if (void 0 === e.scrollbarSize) { var t = document.createElement("div"); t.style.cssText = "width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;", document.body.appendChild(t), e.scrollbarSize = t.offsetWidth - t.clientWidth, document.body.removeChild(t) } return e.scrollbarSize } }, t.magnificPopup = { instance: null, proto: w.prototype, modules: [], open: function(e, o) { return L(), e = e ? t.extend(!0, {}, e) : {}, e.isObj = !0, e.index = o || 0, this.instance.open(e) }, close: function() { return t.magnificPopup.instance && t.magnificPopup.instance.close() }, registerModule: function(e, o) { o.options && (t.magnificPopup.defaults[e] = o.options), t.extend(this.proto, o.proto), this.modules.push(e) }, defaults: { disableOn: 0, key: null, midClick: !1, mainClass: "", preloader: !0, focus: "", closeOnContentClick: !1, closeOnBgClick: !0, closeBtnInside: !0, showCloseBtn: !0, enableEscapeKey: !0, modal: !1, alignTop: !1, removalDelay: 0, prependTo: null, fixedContentPos: "auto", fixedBgPos: "auto", overflowY: "auto", closeMarkup: '', tClose: "Close (Esc)", tLoading: "Loading...", autoFocusLast: !0 } }, t.fn.magnificPopup = function(o) { L(); var i = t(this); if ("string" == typeof o) if ("open" === o) { var n, s = b ? i.data("magnificPopup") : i[0].magnificPopup, r = parseInt(arguments[1], 10) || 0; s.items ? n = s.items[r] : (n = i, s.delegate && (n = n.find(s.delegate)), n = n.eq(r)), e._openClick({ mfpEl: n }, i, s) } else e.isOpen && e[o].apply(e, Array.prototype.slice.call(arguments, 1)); else o = t.extend(!0, {}, o), b ? i.data("magnificPopup", o) : i[0].magnificPopup = o, e.addGroup(i, o); return i }; var E, W, O, _ = "inline", I = function() { O && (W.after(O.addClass(E)).detach(), O = null) }; t.magnificPopup.registerModule(_, { options: { hiddenClass: "hide", markup: "", tNotFound: "Content not found" }, proto: { initInline: function() { e.types.push(_), T(a + "." + _, function() { I() }) }, getInline: function(o, i) { if (I(), o.src) { var n = e.st.inline, s = t(o.src); if (s.length) { var r = s[0].parentNode; r && r.tagName && (W || (E = n.hiddenClass, W = x(E), E = "mfp-" + E), O = s.after(W).detach().removeClass(E)), e.updateStatus("ready") } else e.updateStatus("error", n.tNotFound), s = t("
    "); return o.inlineElement = s, s } return e.updateStatus("ready"), e._parseMarkup(i, {}, o), i } } }); var P, $ = "ajax", D = function() { P && t(document.body).removeClass(P) }, M = function() { D(), e.req && e.req.abort() }; t.magnificPopup.registerModule($, { options: { settings: null, cursor: "mfp-ajax-cur", tError: 'The content could not be loaded.' }, proto: { initAjax: function() { e.types.push($), P = e.st.ajax.cursor, T(a + "." + $, M), T("BeforeChange." + $, M) }, getAjax: function(o) { P && t(document.body).addClass(P), e.updateStatus("loading"); var i = t.extend({ url: o.src, success: function(i, n, s) { var r = { data: i, xhr: s }; k("ParseAjax", r), e.appendContent(t(r.data), $), o.finished = !0, D(), e._setFocus(), setTimeout(function() { e.wrap.addClass(g) }, 16), e.updateStatus("ready"), k("AjaxContentAdded") }, error: function() { D(), o.finished = o.loadError = !0, e.updateStatus("error", e.st.ajax.tError.replace("%url%", o.src)) } }, e.st.ajax.settings); return e.req = t.ajax(i), "" } } }); var R, A = function(o) { if (o.data && void 0 !== o.data.title) return o.data.title; var i = e.st.image.titleSrc; if (i) { if (t.isFunction(i)) return i.call(e, o); if (o.el) return o.el.attr(i) || "" } return "" }; t.magnificPopup.registerModule("image", { options: { markup: '
    ', cursor: "mfp-zoom-out-cur", titleSrc: "title", verticalFit: !0, tError: 'The image could not be loaded.' }, proto: { initImage: function() { var o = e.st.image, i = ".image"; e.types.push("image"), T(p + i, function() { "image" === e.currItem.type && o.cursor && t(document.body).addClass(o.cursor) }), T(a + i, function() { o.cursor && t(document.body).removeClass(o.cursor), z.off("resize" + m) }), T("Resize" + i, e.resizeImage), e.isLowIE && T("AfterChange", e.resizeImage) }, resizeImage: function() { var t = e.currItem; if (t && t.img && e.st.image.verticalFit) { var o = 0; e.isLowIE && (o = parseInt(t.img.css("padding-top"), 10) + parseInt(t.img.css("padding-bottom"), 10)), t.img.css("max-height", e.wH - o) } }, _onImageHasSize: function(t) { t.img && (t.hasSize = !0, R && clearInterval(R), t.isCheckingImgSize = !1, k("ImageHasSize", t), t.imgHidden && (e.content && e.content.removeClass("mfp-loading"), t.imgHidden = !1)) }, findImageSize: function(t) { var o = 0, i = t.img[0], n = function(s) { R && clearInterval(R), R = setInterval(function() { return i.naturalWidth > 0 ? void e._onImageHasSize(t) : (o > 200 && clearInterval(R), o++, void(3 === o ? n(10) : 40 === o ? n(50) : 100 === o && n(500))) }, s) }; n(1) }, getImage: function(o, i) { var n = 0, s = function() { o && (o.img[0].complete ? (o.img.off(".mfploader"), o === e.currItem && (e._onImageHasSize(o), e.updateStatus("ready")), o.hasSize = !0, o.loaded = !0, k("ImageLoadComplete")) : (n++, n < 200 ? setTimeout(s, 100) : r())) }, r = function() { o && (o.img.off(".mfploader"), o === e.currItem && (e._onImageHasSize(o), e.updateStatus("error", a.tError.replace("%url%", o.src))), o.hasSize = !0, o.loaded = !0, o.loadError = !0) }, a = e.st.image, l = i.find(".mfp-img"); if (l.length) { var h = document.createElement("img"); h.className = "mfp-img", o.el && o.el.find("img").length && (h.alt = o.el.find("img").attr("alt")), o.img = t(h).on("load.mfploader", s).on("error.mfploader", r), h.src = o.src, l.is("img") && (o.img = o.img.clone()), h = o.img[0], h.naturalWidth > 0 ? o.hasSize = !0 : h.width || (o.hasSize = !1) } return e._parseMarkup(i, { title: A(o), img_replaceWith: o.img }, o), e.resizeImage(), o.hasSize ? (R && clearInterval(R), o.loadError ? (i.addClass("mfp-loading"), e.updateStatus("error", a.tError.replace("%url%", o.src))) : (i.removeClass("mfp-loading"), e.updateStatus("ready")), i) : (e.updateStatus("loading"), o.loading = !0, o.hasSize || (o.imgHidden = !0, i.addClass("mfp-loading"), e.findImageSize(o)), i) } } }); var H, N = function() { return void 0 === H && (H = void 0 !== document.createElement("p").style.MozTransform), H }; t.magnificPopup.registerModule("zoom", { options: { enabled: !1, easing: "ease-in-out", duration: 300, opener: function(t) { return t.is("img") ? t : t.find("img") } }, proto: { initZoom: function() { var t, o = e.st.zoom, i = ".zoom"; if (o.enabled && e.supportsTransition) { var n, s, r = o.duration, h = function(t) { var e = t.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image"), i = "all " + o.duration / 1e3 + "s " + o.easing, n = { position: "fixed", zIndex: 9999, left: 0, top: 0, "-webkit-backface-visibility": "hidden" }, s = "transition"; return n["-webkit-" + s] = n["-moz-" + s] = n["-o-" + s] = n[s] = i, e.css(n), e }, d = function() { e.content.css("visibility", "visible") }; T("BuildControls" + i, function() { if (e._allowZoom()) { if (clearTimeout(n), e.content.css("visibility", "hidden"), t = e._getItemToZoom(), !t) return void d(); s = h(t), s.css(e._getOffset()), e.wrap.append(s), n = setTimeout(function() { s.css(e._getOffset(!0)), n = setTimeout(function() { d(), setTimeout(function() { s.remove(), t = s = null, k("ZoomAnimationEnded") }, 16) }, r) }, 16) } }), T(l + i, function() { if (e._allowZoom()) { if (clearTimeout(n), e.st.removalDelay = r, !t) { if (t = e._getItemToZoom(), !t) return; s = h(t) } s.css(e._getOffset(!0)), e.wrap.append(s), e.content.css("visibility", "hidden"), setTimeout(function() { s.css(e._getOffset()) }, 16) } }), T(a + i, function() { e._allowZoom() && (d(), s && s.remove(), t = null) }) } }, _allowZoom: function() { return "image" === e.currItem.type }, _getItemToZoom: function() { return !!e.currItem.hasSize && e.currItem.img }, _getOffset: function(o) { var i; i = o ? e.currItem.img : e.st.zoom.opener(e.currItem.el || e.currItem); var n = i.offset(), s = parseInt(i.css("padding-top"), 10), r = parseInt(i.css("padding-bottom"), 10); n.top -= t(window).scrollTop() - s; var a = { width: i.width(), height: (b ? i.innerHeight() : i[0].offsetHeight) - r - s }; return N() ? a["-moz-transform"] = a.transform = "translate(" + n.left + "px," + n.top + "px)" : (a.left = n.left, a.top = n.top), a } } }); var j = "iframe", B = "//about:blank", F = function(t) { if (e.currTemplate[j]) { var o = e.currTemplate[j].find("iframe"); o.length && (t || (o[0].src = B), e.isIE8 && o.css("display", t ? "block" : "none")) } }; t.magnificPopup.registerModule(j, { options: { markup: '
    ', srcAction: "iframe_src", patterns: { youtube: { index: "youtube.com", id: "v=", src: "//www.youtube.com/embed/%id%?autoplay=1" }, vimeo: { index: "vimeo.com/", id: "/", src: "//player.vimeo.com/video/%id%?autoplay=1" }, gmaps: { index: "//maps.google.", src: "%id%&output=embed" } } }, proto: { initIframe: function() { e.types.push(j), T("BeforeChange", function(t, e, o) { e !== o && (e === j ? F() : o === j && F(!0)) }), T(a + "." + j, function() { F() }) }, getIframe: function(o, i) { var n = o.src, s = e.st.iframe; t.each(s.patterns, function() { if (n.indexOf(this.index) > -1) return this.id && (n = "string" == typeof this.id ? n.substr(n.lastIndexOf(this.id) + this.id.length, n.length) : this.id.call(this, n)), n = this.src.replace("%id%", n), !1 }); var r = {}; return s.srcAction && (r[s.srcAction] = n), e._parseMarkup(i, r, o), e.updateStatus("ready"), i } } }); var Y = function(t) { var o = e.items.length; return t > o - 1 ? t - o : t < 0 ? o + t : t }, U = function(t, e, o) { return t.replace(/%curr%/gi, e + 1).replace(/%total%/gi, o) }; t.magnificPopup.registerModule("gallery", { options: { enabled: !1, arrowMarkup: '', preload: [0, 2], navigateByImgClick: !0, arrows: !0, tPrev: "Previous (Left arrow key)", tNext: "Next (Right arrow key)", tCounter: "%curr% of %total%" }, proto: { initGallery: function() { var o = e.st.gallery, n = ".mfp-gallery"; return e.direction = !0, !(!o || !o.enabled) && (s += " mfp-gallery", T(p + n, function() { o.navigateByImgClick && e.wrap.on("click" + n, ".mfp-img", function() { if (e.items.length > 1) return e.next(), !1 }), i.on("keydown" + n, function(t) { 37 === t.keyCode ? e.prev() : 39 === t.keyCode && e.next() }) }), T("UpdateStatus" + n, function(t, o) { o.text && (o.text = U(o.text, e.currItem.index, e.items.length)) }), T(c + n, function(t, i, n, s) { var r = e.items.length; n.counter = r > 1 ? U(o.tCounter, s.index, r) : "" }), T("BuildControls" + n, function() { if (e.items.length > 1 && o.arrows && !e.arrowLeft) { var i = o.arrowMarkup, n = e.arrowLeft = t(i.replace(/%title%/gi, o.tPrev).replace(/%dir%/gi, "left")).addClass(y), s = e.arrowRight = t(i.replace(/%title%/gi, o.tNext).replace(/%dir%/gi, "right")).addClass(y); n.click(function() { e.prev() }), s.click(function() { e.next() }), e.container.append(n.add(s)) } }), T(u + n, function() { e._preloadTimeout && clearTimeout(e._preloadTimeout), e._preloadTimeout = setTimeout(function() { e.preloadNearbyImages(), e._preloadTimeout = null }, 16) }), void T(a + n, function() { i.off(n), e.wrap.off("click" + n), e.arrowRight = e.arrowLeft = null })) }, next: function() { e.direction = !0, e.index = Y(e.index + 1), e.updateItemHTML() }, prev: function() { e.direction = !1, e.index = Y(e.index - 1), e.updateItemHTML() }, goTo: function(t) { e.direction = t >= e.index, e.index = t, e.updateItemHTML() }, preloadNearbyImages: function() { var t, o = e.st.gallery.preload, i = Math.min(o[0], e.items.length), n = Math.min(o[1], e.items.length); for (t = 1; t <= (e.direction ? n : i); t++) e._preloadItem(e.index + t); for (t = 1; t <= (e.direction ? i : n); t++) e._preloadItem(e.index - t) }, _preloadItem: function(o) { if (o = Y(o), !e.items[o].preloaded) { var i = e.items[o]; i.parsed || (i = e.parseEl(o)), k("LazyLoad", i), "image" === i.type && (i.img = t('').on("load.mfploader", function() { i.hasSize = !0 }).on("error.mfploader", function() { i.hasSize = !0, i.loadError = !0, k("LazyLoadError", i) }).attr("src", i.src)), i.preloaded = !0 } } } }); var q = "retina"; t.magnificPopup.registerModule(q, { options: { replaceSrc: function(t) { return t.src.replace(/\.\w+$/, function(t) { return "@2x" + t }) }, ratio: 1 }, proto: { initRetina: function() { if (window.devicePixelRatio > 1) { var t = e.st.retina, o = t.ratio; o = isNaN(o) ? o() : o, o > 1 && (T("ImageHasSize." + q, function(t, e) { e.img.css({ "max-width": e.img[0].naturalWidth / o, width: "100%" }) }), T("ElementParse." + q, function(e, i) { i.src = t.replaceSrc(i, o) })) } } } }), L() }), ! function(t) { var e = { animation: "dissolve", separator: ",", speed: 2e3 }; t.fx.step.textShadowBlur = function(e) { t(e.elem).prop("textShadowBlur", e.now).css({ textShadow: "0 0 " + Math.floor(e.now) + "px black" }) }, t.fn.textrotator = function(o) { var i = t.extend({}, e, o); return this.each(function() { var e = t(this), o = []; t.each(e.text().split(i.separator), function(t, e) { o.push(e) }), e.text(o[0]); var n = function() { switch (i.animation) { case "dissolve": e.animate({ textShadowBlur: 20, opacity: 0 }, 500, function() { s = t.inArray(e.text(), o), s + 1 == o.length && (s = -1), e.text(o[s + 1]).animate({ textShadowBlur: 0, opacity: 1 }, 500) }); break; case "flip": e.find(".back").length > 0 && e.html(e.find(".back").html()); var n = e.text(), s = t.inArray(n, o); s + 1 == o.length && (s = -1), e.html(""), t("" + n + "").appendTo(e), t("" + o[s + 1] + "").appendTo(e), e.wrapInner("").find(".rotating").hide().addClass("flip").show().css({ "-webkit-transform": " rotateY(-180deg)", "-moz-transform": " rotateY(-180deg)", "-o-transform": " rotateY(-180deg)", transform: " rotateY(-180deg)" }); break; case "flipUp": e.find(".back").length > 0 && e.html(e.find(".back").html()); var n = e.text(), s = t.inArray(n, o); s + 1 == o.length && (s = -1), e.html(""), t("" + n + "").appendTo(e), t("" + o[s + 1] + "").appendTo(e), e.wrapInner("").find(".rotating").hide().addClass("flip up").show().css({ "-webkit-transform": " rotateX(-180deg)", "-moz-transform": " rotateX(-180deg)", "-o-transform": " rotateX(-180deg)", transform: " rotateX(-180deg)" }); break; case "flipCube": e.find(".back").length > 0 && e.html(e.find(".back").html()); var n = e.text(), s = t.inArray(n, o); s + 1 == o.length && (s = -1), e.html(""), t("" + n + "").appendTo(e), t("" + o[s + 1] + "").appendTo(e), e.wrapInner("").find(".rotating").hide().addClass("flip cube").show().css({ "-webkit-transform": " rotateY(180deg)", "-moz-transform": " rotateY(180deg)", "-o-transform": " rotateY(180deg)", transform: " rotateY(180deg)" }); break; case "flipCubeUp": e.find(".back").length > 0 && e.html(e.find(".back").html()); var n = e.text(), s = t.inArray(n, o); s + 1 == o.length && (s = -1), e.html(""), t("" + n + "").appendTo(e), t("" + o[s + 1] + "").appendTo(e), e.wrapInner("").find(".rotating").hide().addClass("flip cube up").show().css({ "-webkit-transform": " rotateX(180deg)", "-moz-transform": " rotateX(180deg)", "-o-transform": " rotateX(180deg)", transform: " rotateX(180deg)" }); break; case "spin": e.find(".rotating").length > 0 && e.html(e.find(".rotating").html()), s = t.inArray(e.text(), o), s + 1 == o.length && (s = -1), e.wrapInner("").find(".rotating").hide().text(o[s + 1]).show().css({ "-webkit-transform": " rotate(0) scale(1)", "-moz-transform": "rotate(0) scale(1)", "-o-transform": "rotate(0) scale(1)", transform: "rotate(0) scale(1)" }); break; case "fade": e.fadeOut(i.speed, function() { s = t.inArray(e.text(), o), s + 1 == o.length && (s = -1), e.text(o[s + 1]).fadeIn(i.speed) }) } }; setInterval(n, i.speed) }) } }(window.jQuery), ! function(t) { function e() {} function o(t) { function o(e) { e.prototype.option || (e.prototype.option = function(e) { t.isPlainObject(e) && (this.options = t.extend(!0, this.options, e)) }) } function n(e, o) { t.fn[e] = function(n) { if ("string" == typeof n) { for (var r = i.call(arguments, 1), a = 0, l = this.length; l > a; a++) { var h = this[a], d = t.data(h, e); if (d) if (t.isFunction(d[n]) && "_" !== n.charAt(0)) { var c = d[n].apply(d, r); if (void 0 !== c) return c } else s("no such method '" + n + "' for " + e + " instance"); else s("cannot call methods on " + e + " prior to initialization; attempted to call '" + n + "'") } return this } return this.each(function() { var i = t.data(this, e); i ? (i.option(n), i._init()) : (i = new o(this, n), t.data(this, e, i)) }) } } if (t) { var s = "undefined" == typeof console ? e : function(t) { console.error(t) }; return t.bridget = function(t, e) { o(e), n(t, e) }, t.bridget } } var i = Array.prototype.slice; "function" == typeof define && define.amd ? define("jquery-bridget/jquery.bridget", ["jquery"], o) : o("object" == typeof exports ? require("jquery") : t.jQuery) }(window), function(t) { function e(e) { var o = t.event; return o.target = o.target || o.srcElement || e, o } var o = document.documentElement, i = function() {}; o.addEventListener ? i = function(t, e, o) { t.addEventListener(e, o, !1) } : o.attachEvent && (i = function(t, o, i) { t[o + i] = i.handleEvent ? function() { var o = e(t); i.handleEvent.call(i, o) } : function() { var o = e(t); i.call(t, o) }, t.attachEvent("on" + o, t[o + i]) }); var n = function() {}; o.removeEventListener ? n = function(t, e, o) { t.removeEventListener(e, o, !1) } : o.detachEvent && (n = function(t, e, o) { t.detachEvent("on" + e, t[e + o]); try { delete t[e + o] } catch (i) { t[e + o] = void 0 } }); var s = { bind: i, unbind: n }; "function" == typeof define && define.amd ? define("eventie/eventie", s) : "object" == typeof exports ? module.exports = s : t.eventie = s }(this), function(t) { function e(t) { "function" == typeof t && (e.isReady ? t() : r.push(t)) } function o(t) { var o = "readystatechange" === t.type && "complete" !== s.readyState; e.isReady || o || i() } function i() { e.isReady = !0; for (var t = 0, o = r.length; o > t; t++) { var i = r[t]; i() } } function n(n) { return "complete" === s.readyState ? i() : (n.bind(s, "DOMContentLoaded", o), n.bind(s, "readystatechange", o), n.bind(t, "load", o)), e } var s = t.document, r = []; e.isReady = !1, "function" == typeof define && define.amd ? define("doc-ready/doc-ready", ["eventie/eventie"], n) : "object" == typeof exports ? module.exports = n(require("eventie")) : t.docReady = n(t.eventie) }(window), function() { function t() {} function e(t, e) { for (var o = t.length; o--;) if (t[o].listener === e) return o; return -1 } function o(t) { return function() { return this[t].apply(this, arguments) } } var i = t.prototype, n = this, s = n.EventEmitter; i.getListeners = function(t) { var e, o, i = this._getEvents(); if (t instanceof RegExp) { e = {}; for (o in i) i.hasOwnProperty(o) && t.test(o) && (e[o] = i[o]) } else e = i[t] || (i[t] = []); return e }, i.flattenListeners = function(t) { var e, o = []; for (e = 0; e < t.length; e += 1) o.push(t[e].listener); return o }, i.getListenersAsObject = function(t) { var e, o = this.getListeners(t); return o instanceof Array && (e = {}, e[t] = o), e || o }, i.addListener = function(t, o) { var i, n = this.getListenersAsObject(t), s = "object" == typeof o; for (i in n) n.hasOwnProperty(i) && -1 === e(n[i], o) && n[i].push(s ? o : { listener: o, once: !1 }); return this }, i.on = o("addListener"), i.addOnceListener = function(t, e) { return this.addListener(t, { listener: e, once: !0 }) }, i.once = o("addOnceListener"), i.defineEvent = function(t) { return this.getListeners(t), this }, i.defineEvents = function(t) { for (var e = 0; e < t.length; e += 1) this.defineEvent(t[e]); return this }, i.removeListener = function(t, o) { var i, n, s = this.getListenersAsObject(t); for (n in s) s.hasOwnProperty(n) && (i = e(s[n], o), -1 !== i && s[n].splice(i, 1)); return this }, i.off = o("removeListener"), i.addListeners = function(t, e) { return this.manipulateListeners(!1, t, e) }, i.removeListeners = function(t, e) { return this.manipulateListeners(!0, t, e) }, i.manipulateListeners = function(t, e, o) { var i, n, s = t ? this.removeListener : this.addListener, r = t ? this.removeListeners : this.addListeners; if ("object" != typeof e || e instanceof RegExp) for (i = o.length; i--;) s.call(this, e, o[i]); else for (i in e) e.hasOwnProperty(i) && (n = e[i]) && ("function" == typeof n ? s.call(this, i, n) : r.call(this, i, n)); return this }, i.removeEvent = function(t) { var e, o = typeof t, i = this._getEvents(); if ("string" === o) delete i[t]; else if (t instanceof RegExp) for (e in i) i.hasOwnProperty(e) && t.test(e) && delete i[e]; else delete this._events; return this }, i.removeAllListeners = o("removeEvent"), i.emitEvent = function(t, e) { var o, i, n, s, r = this.getListenersAsObject(t); for (n in r) if (r.hasOwnProperty(n)) for (i = r[n].length; i--;) o = r[n][i], o.once === !0 && this.removeListener(t, o.listener), s = o.listener.apply(this, e || []), s === this._getOnceReturnValue() && this.removeListener(t, o.listener); return this }, i.trigger = o("emitEvent"), i.emit = function(t) { var e = Array.prototype.slice.call(arguments, 1); return this.emitEvent(t, e) }, i.setOnceReturnValue = function(t) { return this._onceReturnValue = t, this }, i._getOnceReturnValue = function() { return !this.hasOwnProperty("_onceReturnValue") || this._onceReturnValue }, i._getEvents = function() { return this._events || (this._events = {}) }, t.noConflict = function() { return n.EventEmitter = s, t }, "function" == typeof define && define.amd ? define("eventEmitter/EventEmitter", [], function() { return t }) : "object" == typeof module && module.exports ? module.exports = t : n.EventEmitter = t }.call(this), function(t) { function e(t) { if (t) { if ("string" == typeof i[t]) return t; t = t.charAt(0).toUpperCase() + t.slice(1); for (var e, n = 0, s = o.length; s > n; n++) if (e = o[n] + t, "string" == typeof i[e]) return e } } var o = "Webkit Moz ms Ms O".split(" "), i = document.documentElement.style; "function" == typeof define && define.amd ? define("get-style-property/get-style-property", [], function() { return e }) : "object" == typeof exports ? module.exports = e : t.getStyleProperty = e }(window), function(t) { function e(t) { var e = parseFloat(t), o = -1 === t.indexOf("%") && !isNaN(e); return o && e } function o() { for (var t = { width: 0, height: 0, innerWidth: 0, innerHeight: 0, outerWidth: 0, outerHeight: 0 }, e = 0, o = s.length; o > e; e++) { var i = s[e]; t[i] = 0 } return t } function i(i) { function r() { if (!p) { p = !0; var o = t.getComputedStyle; if (h = function() { var t = o ? function(t) { return o(t, null) } : function(t) { return t.currentStyle }; return function(e) { var o = t(e); return o || n("Style returned " + o + ". Are you running this code in a hidden iframe on Firefox? See http://bit.ly/getsizeiframe"), o } }(), d = i("boxSizing")) { var s = document.createElement("div"); s.style.width = "200px", s.style.padding = "1px 2px 3px 4px", s.style.borderStyle = "solid", s.style.borderWidth = "1px 2px 3px 4px", s.style[d] = "border-box"; var r = document.body || document.documentElement; r.appendChild(s); var a = h(s); c = 200 === e(a.width), r.removeChild(s) } } } function a(t) { if (r(), "string" == typeof t && (t = document.querySelector(t)), t && "object" == typeof t && t.nodeType) { var i = h(t); if ("none" === i.display) return o(); var n = {}; n.width = t.offsetWidth, n.height = t.offsetHeight; for (var a = n.isBorderBox = !(!d || !i[d] || "border-box" !== i[d]), p = 0, u = s.length; u > p; p++) { var f = s[p], m = i[f]; m = l(t, m); var g = parseFloat(m); n[f] = isNaN(g) ? 0 : g } var v = n.paddingLeft + n.paddingRight, y = n.paddingTop + n.paddingBottom, w = n.marginLeft + n.marginRight, b = n.marginTop + n.marginBottom, z = n.borderLeftWidth + n.borderRightWidth, T = n.borderTopWidth + n.borderBottomWidth, x = a && c, k = e(i.width); k !== !1 && (n.width = k + (x ? 0 : v + z)); var C = e(i.height); return C !== !1 && (n.height = C + (x ? 0 : y + T)), n.innerWidth = n.width - (v + z), n.innerHeight = n.height - (y + T), n.outerWidth = n.width + w, n.outerHeight = n.height + b, n } } function l(t, e) { if (getComputedStyle || -1 === e.indexOf("%")) return e; var o = t.style, i = o.left, n = t.runtimeStyle, s = n && n.left; return s && (n.left = t.currentStyle.left), o.left = e, e = o.pixelLeft, o.left = i, s && (n.left = s), e } var h, d, c, p = !1; return a } var n = "undefined" == typeof console ? noop : function(t) { console.error(t) }, s = ["paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "marginLeft", "marginRight", "marginTop", "marginBottom", "borderLeftWidth", "borderRightWidth", "borderTopWidth", "borderBottomWidth"]; "function" == typeof define && define.amd ? define("get-size/get-size", ["get-style-property/get-style-property"], i) : "object" == typeof exports ? module.exports = i(require("desandro-get-style-property")) : t.getSize = i(t.getStyleProperty) }(window), function(t) { function e(t, e) { return t[r](e) } function o(t) { if (!t.parentNode) { var e = document.createDocumentFragment(); e.appendChild(t) } } function i(t, e) { o(t); for (var i = t.parentNode.querySelectorAll(e), n = 0, s = i.length; s > n; n++) if (i[n] === t) return !0; return !1 } function n(t, i) { return o(t), e(t, i) } var s, r = function() { if (t.matchesSelector) return "matchesSelector"; for (var e = ["webkit", "moz", "ms", "o"], o = 0, i = e.length; i > o; o++) { var n = e[o], s = n + "MatchesSelector"; if (t[s]) return s } }(); if (r) { var a = document.createElement("div"), l = e(a, "div"); s = l ? e : n } else s = i; "function" == typeof define && define.amd ? define("matches-selector/matches-selector", [], function() { return s }) : "object" == typeof exports ? module.exports = s : window.matchesSelector = s }(Element.prototype), function(t) { function e(t, e) { for (var o in e) t[o] = e[o]; return t } function o(t) { for (var e in t) return !1; return e = null, !0 } function i(t) { return t.replace(/([A-Z])/g, function(t) { return "-" + t.toLowerCase() }) } function n(t, n, s) { function a(t, e) { t && (this.element = t, this.layout = e, this.position = { x: 0, y: 0 }, this._create()) } var l = s("transition"), h = s("transform"), d = l && h, c = !!s("perspective"), p = { WebkitTransition: "webkitTransitionEnd", MozTransition: "transitionend", OTransition: "otransitionend", transition: "transitionend" }[l], u = ["transform", "transition", "transitionDuration", "transitionProperty"], f = function() { for (var t = {}, e = 0, o = u.length; o > e; e++) { var i = u[e], n = s(i); n && n !== i && (t[i] = n) } return t }(); e(a.prototype, t.prototype), a.prototype._create = function() { this._transn = { ingProperties: {}, clean: {}, onEnd: {} }, this.css({ position: "absolute" }) }, a.prototype.handleEvent = function(t) { var e = "on" + t.type; this[e] && this[e](t) }, a.prototype.getSize = function() { this.size = n(this.element) }, a.prototype.css = function(t) { var e = this.element.style; for (var o in t) { var i = f[o] || o; e[i] = t[o] } }, a.prototype.getPosition = function() { var t = r(this.element), e = this.layout.options, o = e.isOriginLeft, i = e.isOriginTop, n = parseInt(t[o ? "left" : "right"], 10), s = parseInt(t[i ? "top" : "bottom"], 10); n = isNaN(n) ? 0 : n, s = isNaN(s) ? 0 : s; var a = this.layout.size; n -= o ? a.paddingLeft : a.paddingRight, s -= i ? a.paddingTop : a.paddingBottom, this.position.x = n, this.position.y = s }, a.prototype.layoutPosition = function() { var t = this.layout.size, e = this.layout.options, o = {}; e.isOriginLeft ? (o.left = this.position.x + t.paddingLeft + "px", o.right = "") : (o.right = this.position.x + t.paddingRight + "px", o.left = ""), e.isOriginTop ? (o.top = this.position.y + t.paddingTop + "px", o.bottom = "") : (o.bottom = this.position.y + t.paddingBottom + "px", o.top = ""), this.css(o), this.emitEvent("layout", [this]) }; var m = c ? function(t, e) { return "translate3d(" + t + "px, " + e + "px, 0)" } : function(t, e) { return "translate(" + t + "px, " + e + "px)" }; a.prototype._transitionTo = function(t, e) { this.getPosition(); var o = this.position.x, i = this.position.y, n = parseInt(t, 10), s = parseInt(e, 10), r = n === this.position.x && s === this.position.y; if (this.setPosition(t, e), r && !this.isTransitioning) return void this.layoutPosition(); var a = t - o, l = e - i, h = {}, d = this.layout.options; a = d.isOriginLeft ? a : -a, l = d.isOriginTop ? l : -l, h.transform = m(a, l), this.transition({ to: h, onTransitionEnd: { transform: this.layoutPosition }, isCleaning: !0 }) }, a.prototype.goTo = function(t, e) { this.setPosition(t, e), this.layoutPosition() }, a.prototype.moveTo = d ? a.prototype._transitionTo : a.prototype.goTo, a.prototype.setPosition = function(t, e) { this.position.x = parseInt(t, 10), this.position.y = parseInt(e, 10) }, a.prototype._nonTransition = function(t) { this.css(t.to), t.isCleaning && this._removeStyles(t.to); for (var e in t.onTransitionEnd) t.onTransitionEnd[e].call(this) }, a.prototype._transition = function(t) { if (!parseFloat(this.layout.options.transitionDuration)) return void this._nonTransition(t); var e = this._transn; for (var o in t.onTransitionEnd) e.onEnd[o] = t.onTransitionEnd[o]; for (o in t.to) e.ingProperties[o] = !0, t.isCleaning && (e.clean[o] = !0); if (t.from) { this.css(t.from); var i = this.element.offsetHeight; i = null } this.enableTransition(t.to), this.css(t.to), this.isTransitioning = !0 }; var g = h && i(h) + ",opacity"; a.prototype.enableTransition = function() { this.isTransitioning || (this.css({ transitionProperty: g, transitionDuration: this.layout.options.transitionDuration }), this.element.addEventListener(p, this, !1)) }, a.prototype.transition = a.prototype[l ? "_transition" : "_nonTransition"], a.prototype.onwebkitTransitionEnd = function(t) { this.ontransitionend(t) }, a.prototype.onotransitionend = function(t) { this.ontransitionend(t) }; var v = { "-webkit-transform": "transform", "-moz-transform": "transform", "-o-transform": "transform" }; a.prototype.ontransitionend = function(t) { if (t.target === this.element) { var e = this._transn, i = v[t.propertyName] || t.propertyName; if (delete e.ingProperties[i], o(e.ingProperties) && this.disableTransition(), i in e.clean && (this.element.style[t.propertyName] = "", delete e.clean[i]), i in e.onEnd) { var n = e.onEnd[i]; n.call(this), delete e.onEnd[i] } this.emitEvent("transitionEnd", [this]) } }, a.prototype.disableTransition = function() { this.removeTransitionStyles(), this.element.removeEventListener(p, this, !1), this.isTransitioning = !1 }, a.prototype._removeStyles = function(t) { var e = {}; for (var o in t) e[o] = ""; this.css(e) }; var y = { transitionProperty: "", transitionDuration: "" }; return a.prototype.removeTransitionStyles = function() { this.css(y) }, a.prototype.removeElem = function() { this.element.parentNode.removeChild(this.element), this.emitEvent("remove", [this]) }, a.prototype.remove = function() { if (!l || !parseFloat(this.layout.options.transitionDuration)) return void this.removeElem(); var t = this; this.on("transitionEnd", function() { return t.removeElem(), !0 }), this.hide() }, a.prototype.reveal = function() { delete this.isHidden, this.css({ display: "" }); var t = this.layout.options; this.transition({ from: t.hiddenStyle, to: t.visibleStyle, isCleaning: !0 }) }, a.prototype.hide = function() { this.isHidden = !0, this.css({ display: "" }); var t = this.layout.options; this.transition({ from: t.visibleStyle, to: t.hiddenStyle, isCleaning: !0, onTransitionEnd: { opacity: function() { this.isHidden && this.css({ display: "none" }) } } }) }, a.prototype.destroy = function() { this.css({ position: "", left: "", right: "", top: "", bottom: "", transition: "", transform: "" }) }, a } var s = t.getComputedStyle, r = s ? function(t) { return s(t, null) } : function(t) { return t.currentStyle }; "function" == typeof define && define.amd ? define("outlayer/item", ["eventEmitter/EventEmitter", "get-size/get-size", "get-style-property/get-style-property"], n) : "object" == typeof exports ? module.exports = n(require("wolfy87-eventemitter"), require("get-size"), require("desandro-get-style-property")) : (t.Outlayer = {}, t.Outlayer.Item = n(t.EventEmitter, t.getSize, t.getStyleProperty)) }(window), function(t) { function e(t, e) { for (var o in e) t[o] = e[o]; return t } function o(t) { return "[object Array]" === c.call(t) } function i(t) { var e = []; if (o(t)) e = t; else if (t && "number" == typeof t.length) for (var i = 0, n = t.length; n > i; i++) e.push(t[i]); else e.push(t); return e } function n(t, e) { var o = u(e, t); - 1 !== o && e.splice(o, 1) } function s(t) { return t.replace(/(.)([A-Z])/g, function(t, e, o) { return e + "-" + o }).toLowerCase() } function r(o, r, c, u, f, m) { function g(t, o) { if ("string" == typeof t && (t = a.querySelector(t)), !t || !p(t)) return void(l && l.error("Bad " + this.constructor.namespace + " element: " + t)); this.element = t, this.options = e({}, this.constructor.defaults), this.option(o); var i = ++v; this.element.outlayerGUID = i, y[i] = this, this._create(), this.options.isInitLayout && this.layout() } var v = 0, y = {}; return g.namespace = "outlayer", g.Item = m, g.defaults = { containerStyle: { position: "relative" }, isInitLayout: !0, isOriginLeft: !0, isOriginTop: !0, isResizeBound: !0, isResizingContainer: !0, transitionDuration: "0.4s", hiddenStyle: { opacity: 0, transform: "scale(0.001)" }, visibleStyle: { opacity: 1, transform: "scale(1)" } }, e(g.prototype, c.prototype), g.prototype.option = function(t) { e(this.options, t) }, g.prototype._create = function() { this.reloadItems(), this.stamps = [], this.stamp(this.options.stamp), e(this.element.style, this.options.containerStyle), this.options.isResizeBound && this.bindResize() }, g.prototype.reloadItems = function() { this.items = this._itemize(this.element.children) }, g.prototype._itemize = function(t) { for (var e = this._filterFindItemElements(t), o = this.constructor.Item, i = [], n = 0, s = e.length; s > n; n++) { var r = e[n], a = new o(r, this); i.push(a) } return i }, g.prototype._filterFindItemElements = function(t) { t = i(t); for (var e = this.options.itemSelector, o = [], n = 0, s = t.length; s > n; n++) { var r = t[n]; if (p(r)) if (e) { f(r, e) && o.push(r); for (var a = r.querySelectorAll(e), l = 0, h = a.length; h > l; l++) o.push(a[l]) } else o.push(r) } return o }, g.prototype.getItemElements = function() { for (var t = [], e = 0, o = this.items.length; o > e; e++) t.push(this.items[e].element); return t }, g.prototype.layout = function() { this._resetLayout(), this._manageStamps(); var t = void 0 !== this.options.isLayoutInstant ? this.options.isLayoutInstant : !this._isLayoutInited; this.layoutItems(this.items, t), this._isLayoutInited = !0 }, g.prototype._init = g.prototype.layout, g.prototype._resetLayout = function() { this.getSize() }, g.prototype.getSize = function() { this.size = u(this.element) }, g.prototype._getMeasurement = function(t, e) { var o, i = this.options[t]; i ? ("string" == typeof i ? o = this.element.querySelector(i) : p(i) && (o = i), this[t] = o ? u(o)[e] : i) : this[t] = 0 }, g.prototype.layoutItems = function(t, e) { t = this._getItemsForLayout(t), this._layoutItems(t, e), this._postLayout() }, g.prototype._getItemsForLayout = function(t) { for (var e = [], o = 0, i = t.length; i > o; o++) { var n = t[o]; n.isIgnored || e.push(n) } return e }, g.prototype._layoutItems = function(t, e) { function o() { i.emitEvent("layoutComplete", [i, t]) } var i = this; if (!t || !t.length) return void o(); this._itemsOn(t, "layout", o); for (var n = [], s = 0, r = t.length; r > s; s++) { var a = t[s], l = this._getItemLayoutPosition(a); l.item = a, l.isInstant = e || a.isLayoutInstant, n.push(l) } this._processLayoutQueue(n) }, g.prototype._getItemLayoutPosition = function() { return { x: 0, y: 0 } }, g.prototype._processLayoutQueue = function(t) { for (var e = 0, o = t.length; o > e; e++) { var i = t[e]; this._positionItem(i.item, i.x, i.y, i.isInstant) } }, g.prototype._positionItem = function(t, e, o, i) { i ? t.goTo(e, o) : t.moveTo(e, o) }, g.prototype._postLayout = function() { this.resizeContainer() }, g.prototype.resizeContainer = function() { if (this.options.isResizingContainer) { var t = this._getContainerSize(); t && (this._setContainerMeasure(t.width, !0), this._setContainerMeasure(t.height, !1)) } }, g.prototype._getContainerSize = d, g.prototype._setContainerMeasure = function(t, e) { if (void 0 !== t) { var o = this.size; o.isBorderBox && (t += e ? o.paddingLeft + o.paddingRight + o.borderLeftWidth + o.borderRightWidth : o.paddingBottom + o.paddingTop + o.borderTopWidth + o.borderBottomWidth), t = Math.max(t, 0), this.element.style[e ? "width" : "height"] = t + "px" } }, g.prototype._itemsOn = function(t, e, o) { function i() { return n++, n === s && o.call(r), !0 } for (var n = 0, s = t.length, r = this, a = 0, l = t.length; l > a; a++) { var h = t[a]; h.on(e, i) } }, g.prototype.ignore = function(t) { var e = this.getItem(t); e && (e.isIgnored = !0) }, g.prototype.unignore = function(t) { var e = this.getItem(t); e && delete e.isIgnored }, g.prototype.stamp = function(t) { if (t = this._find(t)) { this.stamps = this.stamps.concat(t); for (var e = 0, o = t.length; o > e; e++) { var i = t[e]; this.ignore(i) } } }, g.prototype.unstamp = function(t) { if (t = this._find(t)) for (var e = 0, o = t.length; o > e; e++) { var i = t[e]; n(i, this.stamps), this.unignore(i) } }, g.prototype._find = function(t) { return t ? ("string" == typeof t && (t = this.element.querySelectorAll(t)), t = i(t)) : void 0 }, g.prototype._manageStamps = function() { if (this.stamps && this.stamps.length) { this._getBoundingRect(); for (var t = 0, e = this.stamps.length; e > t; t++) { var o = this.stamps[t]; this._manageStamp(o) } } }, g.prototype._getBoundingRect = function() { var t = this.element.getBoundingClientRect(), e = this.size; this._boundingRect = { left: t.left + e.paddingLeft + e.borderLeftWidth, top: t.top + e.paddingTop + e.borderTopWidth, right: t.right - (e.paddingRight + e.borderRightWidth), bottom: t.bottom - (e.paddingBottom + e.borderBottomWidth) } }, g.prototype._manageStamp = d, g.prototype._getElementOffset = function(t) { var e = t.getBoundingClientRect(), o = this._boundingRect, i = u(t), n = { left: e.left - o.left - i.marginLeft, top: e.top - o.top - i.marginTop, right: o.right - e.right - i.marginRight, bottom: o.bottom - e.bottom - i.marginBottom }; return n }, g.prototype.handleEvent = function(t) { var e = "on" + t.type; this[e] && this[e](t) }, g.prototype.bindResize = function() { this.isResizeBound || (o.bind(t, "resize", this), this.isResizeBound = !0) }, g.prototype.unbindResize = function() { this.isResizeBound && o.unbind(t, "resize", this), this.isResizeBound = !1 }, g.prototype.onresize = function() { function t() { e.resize(), delete e.resizeTimeout } this.resizeTimeout && clearTimeout(this.resizeTimeout); var e = this; this.resizeTimeout = setTimeout(t, 100) }, g.prototype.resize = function() { this.isResizeBound && this.needsResizeLayout() && this.layout() }, g.prototype.needsResizeLayout = function() { var t = u(this.element), e = this.size && t; return e && t.innerWidth !== this.size.innerWidth }, g.prototype.addItems = function(t) { var e = this._itemize(t); return e.length && (this.items = this.items.concat(e)), e }, g.prototype.appended = function(t) { var e = this.addItems(t); e.length && (this.layoutItems(e, !0), this.reveal(e)) }, g.prototype.prepended = function(t) { var e = this._itemize(t); if (e.length) { var o = this.items.slice(0); this.items = e.concat(o), this._resetLayout(), this._manageStamps(), this.layoutItems(e, !0), this.reveal(e), this.layoutItems(o) } }, g.prototype.reveal = function(t) { var e = t && t.length; if (e) for (var o = 0; e > o; o++) { var i = t[o]; i.reveal() } }, g.prototype.hide = function(t) { var e = t && t.length; if (e) for (var o = 0; e > o; o++) { var i = t[o]; i.hide() } }, g.prototype.getItem = function(t) { for (var e = 0, o = this.items.length; o > e; e++) { var i = this.items[e]; if (i.element === t) return i } }, g.prototype.getItems = function(t) { if (t && t.length) { for (var e = [], o = 0, i = t.length; i > o; o++) { var n = t[o], s = this.getItem(n); s && e.push(s) } return e } }, g.prototype.remove = function(t) { t = i(t); var e = this.getItems(t); if (e && e.length) { this._itemsOn(e, "remove", function() { this.emitEvent("removeComplete", [this, e]) }); for (var o = 0, s = e.length; s > o; o++) { var r = e[o]; r.remove(), n(r, this.items) } } }, g.prototype.destroy = function() { var t = this.element.style; t.height = "", t.position = "", t.width = ""; for (var e = 0, o = this.items.length; o > e; e++) { var i = this.items[e]; i.destroy() } this.unbindResize(); var n = this.element.outlayerGUID; delete y[n], delete this.element.outlayerGUID, h && h.removeData(this.element, this.constructor.namespace) }, g.data = function(t) { var e = t && t.outlayerGUID; return e && y[e] }, g.create = function(t, o) { function i() { g.apply(this, arguments) } return Object.create ? i.prototype = Object.create(g.prototype) : e(i.prototype, g.prototype), i.prototype.constructor = i, i.defaults = e({}, g.defaults), e(i.defaults, o), i.prototype.settings = {}, i.namespace = t, i.data = g.data, i.Item = function() { m.apply(this, arguments) }, i.Item.prototype = new m, r(function() { for (var e = s(t), o = a.querySelectorAll(".js-" + e), n = "data-" + e + "-options", r = 0, d = o.length; d > r; r++) { var c, p = o[r], u = p.getAttribute(n); try { c = u && JSON.parse(u) } catch (t) { l && l.error("Error parsing " + n + " on " + p.nodeName.toLowerCase() + (p.id ? "#" + p.id : "") + ": " + t); continue } var f = new i(p, c); h && h.data(p, t, f) } }), h && h.bridget && h.bridget(t, i), i }, g.Item = m, g } var a = t.document, l = t.console, h = t.jQuery, d = function() {}, c = Object.prototype.toString, p = "function" == typeof HTMLElement || "object" == typeof HTMLElement ? function(t) { return t instanceof HTMLElement } : function(t) { return t && "object" == typeof t && 1 === t.nodeType && "string" == typeof t.nodeName }, u = Array.prototype.indexOf ? function(t, e) { return t.indexOf(e) } : function(t, e) { for (var o = 0, i = t.length; i > o; o++) if (t[o] === e) return o; return -1 }; "function" == typeof define && define.amd ? define("outlayer/outlayer", ["eventie/eventie", "doc-ready/doc-ready", "eventEmitter/EventEmitter", "get-size/get-size", "matches-selector/matches-selector", "./item"], r) : "object" == typeof exports ? module.exports = r(require("eventie"), require("doc-ready"), require("wolfy87-eventemitter"), require("get-size"), require("desandro-matches-selector"), require("./item")) : t.Outlayer = r(t.eventie, t.docReady, t.EventEmitter, t.getSize, t.matchesSelector, t.Outlayer.Item) }(window), function(t) { function e(t, e) { var i = t.create("masonry"); return i.prototype._resetLayout = function() { this.getSize(), this._getMeasurement("columnWidth", "outerWidth"), this._getMeasurement("gutter", "outerWidth"), this.measureColumns(); var t = this.cols; for (this.colYs = []; t--;) this.colYs.push(0); this.maxY = 0 }, i.prototype.measureColumns = function() { if (this.getContainerWidth(), !this.columnWidth) { var t = this.items[0], o = t && t.element; this.columnWidth = o && e(o).outerWidth || this.containerWidth } this.columnWidth += this.gutter, this.cols = Math.floor((this.containerWidth + this.gutter) / this.columnWidth), this.cols = Math.max(this.cols, 1) }, i.prototype.getContainerWidth = function() { var t = this.options.isFitWidth ? this.element.parentNode : this.element, o = e(t); this.containerWidth = o && o.innerWidth }, i.prototype._getItemLayoutPosition = function(t) { t.getSize(); var e = t.size.outerWidth % this.columnWidth, i = e && 1 > e ? "round" : "ceil", n = Math[i](t.size.outerWidth / this.columnWidth); n = Math.min(n, this.cols); for (var s = this._getColGroup(n), r = Math.min.apply(Math, s), a = o(s, r), l = { x: this.columnWidth * a, y: r }, h = r + t.size.outerHeight, d = this.cols + 1 - s.length, c = 0; d > c; c++) this.colYs[a + c] = h; return l }, i.prototype._getColGroup = function(t) { if (2 > t) return this.colYs; for (var e = [], o = this.cols + 1 - t, i = 0; o > i; i++) { var n = this.colYs.slice(i, i + t); e[i] = Math.max.apply(Math, n) } return e }, i.prototype._manageStamp = function(t) { var o = e(t), i = this._getElementOffset(t), n = this.options.isOriginLeft ? i.left : i.right, s = n + o.outerWidth, r = Math.floor(n / this.columnWidth); r = Math.max(0, r); var a = Math.floor(s / this.columnWidth); a -= s % this.columnWidth ? 0 : 1, a = Math.min(this.cols - 1, a); for (var l = (this.options.isOriginTop ? i.top : i.bottom) + o.outerHeight, h = r; a >= h; h++) this.colYs[h] = Math.max(l, this.colYs[h]) }, i.prototype._getContainerSize = function() { this.maxY = Math.max.apply(Math, this.colYs); var t = { height: this.maxY }; return this.options.isFitWidth && (t.width = this._getContainerFitWidth()), t }, i.prototype._getContainerFitWidth = function() { for (var t = 0, e = this.cols; --e && 0 === this.colYs[e];) t++; return (this.cols - t) * this.columnWidth - this.gutter }, i.prototype.needsResizeLayout = function() { var t = this.containerWidth; return this.getContainerWidth(), t !== this.containerWidth }, i } var o = Array.prototype.indexOf ? function(t, e) { return t.indexOf(e) } : function(t, e) { for (var o = 0, i = t.length; i > o; o++) { var n = t[o]; if (n === e) return o } return -1 }; "function" == typeof define && define.amd ? define(["outlayer/outlayer", "get-size/get-size"], e) : "object" == typeof exports ? module.exports = e(require("outlayer"), require("get-size")) : t.Masonry = e(t.Outlayer, t.getSize) }(window), window.Modernizr = function(t, e, o) { function i(t) { y.cssText = t } function n(t, e) { return typeof t === e } function s(t, e) { return !!~("" + t).indexOf(e) } function r(t, e) { for (var i in t) { var n = t[i]; if (!s(n, "-") && y[n] !== o) return "pfx" != e || n } return !1 } function a(t, e, i) { for (var s in t) { var r = e[t[s]]; if (r !== o) return i === !1 ? t[s] : n(r, "function") ? r.bind(i || e) : r } return !1 } function l(t, e, o) { var i = t.charAt(0).toUpperCase() + t.slice(1), s = (t + " " + b.join(i + " ") + i).split(" "); return n(e, "string") || n(e, "undefined") ? r(s, e) : (s = (t + " " + z.join(i + " ") + i).split(" "), a(s, e, o)) } var h, d, c, p = "2.7.1", u = {}, f = !0, m = e.documentElement, g = "modernizr", v = e.createElement(g), y = v.style, w = ({}.toString, "Webkit Moz O ms"), b = w.split(" "), z = w.toLowerCase().split(" "), T = {}, x = [], k = x.slice, C = {}.hasOwnProperty; c = n(C, "undefined") || n(C.call, "undefined") ? function(t, e) { return e in t && n(t.constructor.prototype[e], "undefined") } : function(t, e) { return C.call(t, e) }, Function.prototype.bind || (Function.prototype.bind = function(t) { var e = this; if ("function" != typeof e) throw new TypeError; var o = k.call(arguments, 1), i = function() { if (this instanceof i) { var n = function() {}; n.prototype = e.prototype; var s = new n, r = e.apply(s, o.concat(k.call(arguments))); return Object(r) === r ? r : s } return e.apply(t, o.concat(k.call(arguments))) }; return i }), T.cssanimations = function() { return l("animationName") }; for (var L in T) c(T, L) && (d = L.toLowerCase(), u[d] = T[L](), x.push((u[d] ? "" : "no-") + d)); return u.addTest = function(t, e) { if ("object" == typeof t) for (var i in t) c(t, i) && u.addTest(i, t[i]); else { if (t = t.toLowerCase(), u[t] !== o) return u; e = "function" == typeof e ? e() : e, "undefined" != typeof f && f && (m.className += " " + (e ? "" : "no-") + t), u[t] = e } return u }, i(""), v = h = null, function(t, e) { function o(t, e) { var o = t.createElement("p"), i = t.getElementsByTagName("head")[0] || t.documentElement; return o.innerHTML = "x", i.insertBefore(o.lastChild, i.firstChild) } function i() { var t = y.elements; return "string" == typeof t ? t.split(" ") : t } function n(t) { var e = v[t[m]]; return e || (e = {}, g++, t[m] = g, v[g] = e), e } function s(t, o, i) { if (o || (o = e), d) return o.createElement(t); i || (i = n(o)); var s; return s = i.cache[t] ? i.cache[t].cloneNode() : f.test(t) ? (i.cache[t] = i.createElem(t)).cloneNode() : i.createElem(t), !s.canHaveChildren || u.test(t) || s.tagUrn ? s : i.frag.appendChild(s) } function r(t, o) { if (t || (t = e), d) return t.createDocumentFragment(); o = o || n(t); for (var s = o.frag.cloneNode(), r = 0, a = i(), l = a.length; r < l; r++) s.createElement(a[r]); return s } function a(t, e) { e.cache || (e.cache = {}, e.createElem = t.createElement, e.createFrag = t.createDocumentFragment, e.frag = e.createFrag()), t.createElement = function(o) { return y.shivMethods ? s(o, t, e) : e.createElem(o) }, t.createDocumentFragment = Function("h,f", "return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&(" + i().join().replace(/[\w\-]+/g, function(t) { return e.createElem(t), e.frag.createElement(t), 'c("' + t + '")' }) + ");return n}")(y, e.frag) } function l(t) { t || (t = e); var i = n(t); return y.shivCSS && !h && !i.hasCSS && (i.hasCSS = !!o(t, "article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")), d || a(t, i), t } var h, d, c = "3.7.0", p = t.html5 || {}, u = /^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i, f = /^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i, m = "_html5shiv", g = 0, v = {}; ! function() { try { var t = e.createElement("a"); t.innerHTML = "", h = "hidden" in t, d = 1 == t.childNodes.length || function() { e.createElement("a"); var t = e.createDocumentFragment(); return "undefined" == typeof t.cloneNode || "undefined" == typeof t.createDocumentFragment || "undefined" == typeof t.createElement }() } catch (t) { h = !0, d = !0 } }(); var y = { elements: p.elements || "abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video", version: c, shivCSS: p.shivCSS !== !1, supportsUnknownElements: d, shivMethods: p.shivMethods !== !1, type: "default", shivDocument: l, createElement: s, createDocumentFragment: r }; t.html5 = y, l(e) }(this, e), u._version = p, u._domPrefixes = z, u._cssomPrefixes = b, u.testProp = function(t) { return r([t]) }, u.testAllProps = l, u.prefixed = function(t, e, o) { return e ? l(t, e, o) : l(t, "pfx") }, m.className = m.className.replace(/(^|\s)no-js(\s|$)/, "$1$2") + (f ? " js " + x.join(" ") : ""), u }(this, this.document), function(t, e, o) { function i(t) { return "[object Function]" == g.call(t) } function n(t) { return "string" == typeof t } function s() {} function r(t) { return !t || "loaded" == t || "complete" == t || "uninitialized" == t } function a() { var t = v.shift(); y = 1, t ? t.t ? f(function() { ("c" == t.t ? p.injectCss : p.injectJs)(t.s, 0, t.a, t.x, t.e, 1) }, 0) : (t(), a()) : y = 0 } function l(t, o, i, n, s, l, h) { function d(e) { if (!u && r(c.readyState) && (w.r = u = 1, !y && a(), c.onload = c.onreadystatechange = null, e)) { "img" != t && f(function() { z.removeChild(c) }, 50); for (var i in L[o]) L[o].hasOwnProperty(i) && L[o][i].onload() } } var h = h || p.errorTimeout, c = e.createElement(t), u = 0, g = 0, w = { t: i, s: o, e: s, a: l, x: h }; 1 === L[o] && (g = 1, L[o] = []), "object" == t ? c.data = o : (c.src = o, c.type = t), c.width = c.height = "0", c.onerror = c.onload = c.onreadystatechange = function() { d.call(this, g) }, v.splice(n, 0, w), "img" != t && (g || 2 === L[o] ? (z.insertBefore(c, b ? null : m), f(d, h)) : L[o].push(c)) } function h(t, e, o, i, s) { return y = 0, e = e || "j", n(t) ? l("c" == e ? x : T, t, e, this.i++, o, i, s) : (v.splice(this.i++, 0, t), 1 == v.length && a()), this } function d() { var t = p; return t.loader = { load: h, i: 0 }, t } var c, p, u = e.documentElement, f = t.setTimeout, m = e.getElementsByTagName("script")[0], g = {}.toString, v = [], y = 0, w = "MozAppearance" in u.style, b = w && !!e.createRange().compareNode, z = b ? u : m.parentNode, u = t.opera && "[object Opera]" == g.call(t.opera), u = !!e.attachEvent && !u, T = w ? "object" : u ? "script" : "img", x = u ? "script" : T, k = Array.isArray || function(t) { return "[object Array]" == g.call(t) }, C = [], L = {}, S = { timeout: function(t, e) { return e.length && (t.timeout = e[0]), t } }; p = function(t) { function e(t) { var e, o, i, t = t.split("!"), n = C.length, s = t.pop(), r = t.length, s = { url: s, origUrl: s, prefixes: t }; for (o = 0; o < r; o++) i = t[o].split("="), (e = S[i.shift()]) && (s = e(s, i)); for (o = 0; o < n; o++) s = C[o](s); return s } function r(t, n, s, r, a) { var l = e(t), h = l.autoCallback; l.url.split(".").pop().split("?").shift(), l.bypass || (n && (n = i(n) ? n : n[t] || n[r] || n[t.split("/").pop().split("?")[0]]), l.instead ? l.instead(t, n, s, r, a) : (L[l.url] ? l.noexec = !0 : L[l.url] = 1, s.load(l.url, l.forceCSS || !l.forceJS && "css" == l.url.split(".").pop().split("?").shift() ? "c" : o, l.noexec, l.attrs, l.timeout), (i(n) || i(h)) && s.load(function() { d(), n && n(l.origUrl, a, r), h && h(l.origUrl, a, r), L[l.url] = 2 }))) } function a(t, e) { function o(t, o) { if (t) { if (n(t)) o || (c = function() { var t = [].slice.call(arguments); p.apply(this, t), u() }), r(t, c, e, 0, h); else if (Object(t) === t) for (l in a = function() { var e, o = 0; for (e in t) t.hasOwnProperty(e) && o++; return o }(), t) t.hasOwnProperty(l) && (!o && !--a && (i(c) ? c = function() { var t = [].slice.call(arguments); p.apply(this, t), u() } : c[l] = function(t) { return function() { var e = [].slice.call(arguments); t && t.apply(this, e), u() } }(p[l])), r(t[l], c, e, l, h)) } else !o && u() } var a, l, h = !!t.test, d = t.load || t.both, c = t.callback || s, p = c, u = t.complete || s; o(h ? t.yep : t.nope, !!d), d && o(d) } var l, h, c = this.yepnope.loader; if (n(t)) r(t, 0, c, 0); else if (k(t)) for (l = 0; l < t.length; l++) h = t[l], n(h) ? r(h, 0, c, 0) : k(h) ? p(h) : Object(h) === h && a(h, c); else Object(t) === t && a(t, c) }, p.addPrefix = function(t, e) { S[t] = e }, p.addFilter = function(t) { C.push(t) }, p.errorTimeout = 1e4, null == e.readyState && e.addEventListener && (e.readyState = "loading", e.addEventListener("DOMContentLoaded", c = function() { e.removeEventListener("DOMContentLoaded", c, 0), e.readyState = "complete" }, 0)), t.yepnope = d(), t.yepnope.executeStack = a, t.yepnope.injectJs = function(t, o, i, n, l, h) { var d, c, u = e.createElement("script"), n = n || p.errorTimeout; u.src = t; for (c in i) u.setAttribute(c, i[c]); o = h ? a : o || s, u.onreadystatechange = u.onload = function() { !d && r(u.readyState) && (d = 1, o(), u.onload = u.onreadystatechange = null) }, f(function() { d || (d = 1, o(1)) }, n), l ? u.onload() : m.parentNode.insertBefore(u, m) }, t.yepnope.injectCss = function(t, o, i, n, r, l) { var h, n = e.createElement("link"), o = l ? a : o || s; n.href = t, n.rel = "stylesheet", n.type = "text/css"; for (h in i) n.setAttribute(h, i[h]); r || (m.parentNode.insertBefore(n, m), f(o, 0)) } }(this, document), Modernizr.load = function() { yepnope.apply(window, [].slice.call(arguments, 0)) }, function(t, e) { "use strict"; var o; if ("object" == typeof exports) { try { o = require("moment") } catch (t) {} module.exports = e(o) } else "function" == typeof define && define.amd ? define(function(t) { var i = "moment"; try { o = t(i) } catch (t) {} return e(o) }) : t.Pikaday = e(t.moment) }(this, function(t) { "use strict"; var e = "function" == typeof t, o = !!window.addEventListener, i = window.document, n = window.setTimeout, s = function(t, e, i, n) { o ? t.addEventListener(e, i, !!n) : t.attachEvent("on" + e, i) }, r = function(t, e, i, n) { o ? t.removeEventListener(e, i, !!n) : t.detachEvent("on" + e, i) }, a = function(t, e, o) { var n; i.createEvent ? (n = i.createEvent("HTMLEvents"), n.initEvent(e, !0, !1), n = w(n, o), t.dispatchEvent(n)) : i.createEventObject && (n = i.createEventObject(), n = w(n, o), t.fireEvent("on" + e, n)) }, l = function(t) { return t.trim ? t.trim() : t.replace(/^\s+|\s+$/g, "") }, h = function(t, e) { return (" " + t.className + " ").indexOf(" " + e + " ") !== -1 }, d = function(t, e) { h(t, e) || (t.className = "" === t.className ? e : t.className + " " + e) }, c = function(t, e) { t.className = l((" " + t.className + " ").replace(" " + e + " ", " ")) }, p = function(t) { return /Array/.test(Object.prototype.toString.call(t)) }, u = function(t) { return /Date/.test(Object.prototype.toString.call(t)) && !isNaN(t.getTime()) }, f = function(t) { var e = t.getDay(); return 0 === e || 6 === e }, m = function(t) { return t % 4 === 0 && t % 100 !== 0 || t % 400 === 0 }, g = function(t, e) { return [31, m(t) ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][e] }, v = function(t) { u(t) && t.setHours(0, 0, 0, 0) }, y = function(t, e) { return t.getTime() === e.getTime() }, w = function(t, e, o) { var i, n; for (i in e) n = void 0 !== t[i], n && "object" == typeof e[i] && null !== e[i] && void 0 === e[i].nodeName ? u(e[i]) ? o && (t[i] = new Date(e[i].getTime())) : p(e[i]) ? o && (t[i] = e[i].slice(0)) : t[i] = w({}, e[i], o) : !o && n || (t[i] = e[i]); return t }, b = function(t) { return t.month < 0 && (t.year -= Math.ceil(Math.abs(t.month) / 12), t.month += 12), t.month > 11 && (t.year += Math.floor(Math.abs(t.month) / 12), t.month -= 12), t }, z = { field: null, bound: void 0, position: "bottom left", reposition: !0, format: "YYYY-MM-DD", defaultDate: null, setDefaultDate: !1, firstDay: 0, formatStrict: !1, minDate: null, maxDate: null, yearRange: 10, showWeekNumber: !1, minYear: 0, maxYear: 9999, minMonth: void 0, maxMonth: void 0, startRange: null, endRange: null, isRTL: !1, yearSuffix: "", showMonthAfterYear: !1, showDaysInNextAndPreviousMonths: !1, numberOfMonths: 1, mainCalendar: "left", container: void 0, i18n: { previousMonth: "Previous Month", nextMonth: "Next Month", months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], weekdays: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], weekdaysShort: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"] }, theme: null, onSelect: null, onOpen: null, onClose: null, onDraw: null }, T = function(t, e, o) { for (e += t.firstDay; e >= 7;) e -= 7; return o ? t.i18n.weekdaysShort[e] : t.i18n.weekdays[e] }, x = function(t) { var e = [], o = "false"; if (t.isEmpty) { if (!t.showDaysInNextAndPreviousMonths) return ''; e.push("is-outside-current-month") } return t.isDisabled && e.push("is-disabled"), t.isToday && e.push("is-today"), t.isSelected && (e.push("is-selected"), o = "true"), t.isInRange && e.push("is-inrange"), t.isStartRange && e.push("is-startrange"), t.isEndRange && e.push("is-endrange"), '" }, k = function(t, e, o) { var i = new Date(o, 0, 1), n = Math.ceil(((new Date(o, e, t) - i) / 864e5 + i.getDay() + 1) / 7); return '' + n + "" }, C = function(t, e) { return "" + (e ? t.reverse() : t).join("") + "" }, L = function(t) { return "" + t.join("") + "" }, S = function(t) { var e, o = []; for (t.showWeekNumber && o.push(""), e = 0; e < 7; e++) o.push('' + T(t, e, !0) + ""); return "" + (t.isRTL ? o.reverse() : o).join("") + "" }, E = function(t, e, o, i, n, s) { var r, a, l, h, d, c = t._o, u = o === c.minYear, f = o === c.maxYear, m = '
    ', g = !0, v = !0; for (l = [], r = 0; r < 12; r++) l.push('"); for (h = '
    ' + c.i18n.months[i] + '
    ", p(c.yearRange) ? (r = c.yearRange[0], a = c.yearRange[1] + 1) : (r = o - c.yearRange, a = 1 + o + c.yearRange), l = []; r < a && r <= c.maxYear; r++) r >= c.minYear && l.push('"); return d = '
    ' + o + c.yearSuffix + '
    ", m += c.showMonthAfterYear ? d + h : h + d, u && (0 === i || c.minMonth >= i) && (g = !1), f && (11 === i || c.maxMonth <= i) && (v = !1), 0 === e && (m += '"), e === t._o.numberOfMonths - 1 && (m += '"), m += "
    " }, W = function(t, e, o) { return '' + S(t) + L(e) + "
    " }, O = function(r) { var a = this, l = a.config(r); a._onMouseDown = function(t) { if (a._v) { t = t || window.event; var e = t.target || t.srcElement; if (e) if (h(e, "is-disabled") || (!h(e, "pika-button") || h(e, "is-empty") || h(e.parentNode, "is-disabled") ? h(e, "pika-prev") ? a.prevMonth() : h(e, "pika-next") && a.nextMonth() : (a.setDate(new Date(e.getAttribute("data-pika-year"), e.getAttribute("data-pika-month"), e.getAttribute("data-pika-day"))), l.bound && n(function() { a.hide(), l.field && l.field.blur() }, 100))), h(e, "pika-select")) a._c = !0; else { if (!t.preventDefault) return t.returnValue = !1, !1; t.preventDefault() } } }, a._onChange = function(t) { t = t || window.event; var e = t.target || t.srcElement; e && (h(e, "pika-select-month") ? a.gotoMonth(e.value) : h(e, "pika-select-year") && a.gotoYear(e.value)) }, a._onKeyChange = function(t) { if (t = t || window.event, a.isVisible()) switch (t.keyCode) { case 13: case 27: l.field.blur(); break; case 37: t.preventDefault(), a.adjustDate("subtract", 1); break; case 38: a.adjustDate("subtract", 7); break; case 39: a.adjustDate("add", 1); break; case 40: a.adjustDate("add", 7) } }, a._onInputChange = function(o) { var i; o.firedBy !== a && (e ? (i = t(l.field.value, l.format, l.formatStrict), i = i && i.isValid() ? i.toDate() : null) : i = new Date(Date.parse(l.field.value)), u(i) && a.setDate(i), a._v || a.show()) }, a._onInputFocus = function() { a.show() }, a._onInputClick = function() { a.show() }, a._onInputBlur = function() { var t = i.activeElement; do if (h(t, "pika-single")) return; while (t = t.parentNode); a._c || (a._b = n(function() { a.hide() }, 50)), a._c = !1 }, a._onClick = function(t) { t = t || window.event; var e = t.target || t.srcElement, i = e; if (e) { !o && h(e, "pika-select") && (e.onchange || (e.setAttribute("onchange", "return;"), s(e, "change", a._onChange))); do if (h(i, "pika-single") || i === l.trigger) return; while (i = i.parentNode); a._v && e !== l.trigger && i !== l.trigger && a.hide() } }, a.el = i.createElement("div"), a.el.className = "pika-single" + (l.isRTL ? " is-rtl" : "") + (l.theme ? " " + l.theme : ""), s(a.el, "mousedown", a._onMouseDown, !0), s(a.el, "touchend", a._onMouseDown, !0), s(a.el, "change", a._onChange), s(i, "keydown", a._onKeyChange), l.field && (l.container ? l.container.appendChild(a.el) : l.bound ? i.body.appendChild(a.el) : l.field.parentNode.insertBefore(a.el, l.field.nextSibling), s(l.field, "change", a._onInputChange), l.defaultDate || (e && l.field.value ? l.defaultDate = t(l.field.value, l.format).toDate() : l.defaultDate = new Date(Date.parse(l.field.value)), l.setDefaultDate = !0)); var d = l.defaultDate; u(d) ? l.setDefaultDate ? a.setDate(d, !0) : a.gotoDate(d) : a.gotoDate(new Date), l.bound ? (this.hide(), a.el.className += " is-bound", s(l.trigger, "click", a._onInputClick), s(l.trigger, "focus", a._onInputFocus), s(l.trigger, "blur", a._onInputBlur)) : this.show() }; return O.prototype = { config: function(t) { this._o || (this._o = w({}, z, !0)); var e = w(this._o, t, !0); e.isRTL = !!e.isRTL, e.field = e.field && e.field.nodeName ? e.field : null, e.theme = "string" == typeof e.theme && e.theme ? e.theme : null, e.bound = !!(void 0 !== e.bound ? e.field && e.bound : e.field), e.trigger = e.trigger && e.trigger.nodeName ? e.trigger : e.field, e.disableWeekends = !!e.disableWeekends, e.disableDayFn = "function" == typeof e.disableDayFn ? e.disableDayFn : null; var o = parseInt(e.numberOfMonths, 10) || 1; if (e.numberOfMonths = o > 4 ? 4 : o, u(e.minDate) || (e.minDate = !1), u(e.maxDate) || (e.maxDate = !1), e.minDate && e.maxDate && e.maxDate < e.minDate && (e.maxDate = e.minDate = !1), e.minDate && this.setMinDate(e.minDate), e.maxDate && this.setMaxDate(e.maxDate), p(e.yearRange)) { var i = (new Date).getFullYear() - 10; e.yearRange[0] = parseInt(e.yearRange[0], 10) || i, e.yearRange[1] = parseInt(e.yearRange[1], 10) || i } else e.yearRange = Math.abs(parseInt(e.yearRange, 10)) || z.yearRange, e.yearRange > 100 && (e.yearRange = 100); return e }, toString: function(o) { return u(this._d) ? e ? t(this._d).format(o || this._o.format) : this._d.toDateString() : "" }, getMoment: function() { return e ? t(this._d) : null }, setMoment: function(o, i) { e && t.isMoment(o) && this.setDate(o.toDate(), i) }, getDate: function() { return u(this._d) ? new Date(this._d.getTime()) : new Date }, setDate: function(t, e) { if (!t) return this._d = null, this._o.field && (this._o.field.value = "", a(this._o.field, "change", { firedBy: this })), this.draw(); if ("string" == typeof t && (t = new Date(Date.parse(t))), u(t)) { var o = this._o.minDate, i = this._o.maxDate; u(o) && t < o ? t = o : u(i) && t > i && (t = i), this._d = new Date(t.getTime()), v(this._d), this.gotoDate(this._d), this._o.field && (this._o.field.value = this.toString(), a(this._o.field, "change", { firedBy: this })), e || "function" != typeof this._o.onSelect || this._o.onSelect.call(this, this.getDate()) } }, gotoDate: function(t) { var e = !0; if (u(t)) { if (this.calendars) { var o = new Date(this.calendars[0].year, this.calendars[0].month, 1), i = new Date(this.calendars[this.calendars.length - 1].year, this.calendars[this.calendars.length - 1].month, 1), n = t.getTime(); i.setMonth(i.getMonth() + 1), i.setDate(i.getDate() - 1), e = n < o.getTime() || i.getTime() < n } e && (this.calendars = [{ month: t.getMonth(), year: t.getFullYear() }], "right" === this._o.mainCalendar && (this.calendars[0].month += 1 - this._o.numberOfMonths)), this.adjustCalendars() } }, adjustDate: function(o, i) { var n, s = this.getDate(), r = 24 * parseInt(i) * 60 * 60 * 1e3; "add" === o ? n = new Date(s.valueOf() + r) : "subtract" === o && (n = new Date(s.valueOf() - r)), e && ("add" === o ? n = t(s).add(i, "days").toDate() : "subtract" === o && (n = t(s).subtract(i, "days").toDate())), this.setDate(n) }, adjustCalendars: function() { this.calendars[0] = b(this.calendars[0]); for (var t = 1; t < this._o.numberOfMonths; t++) this.calendars[t] = b({ month: this.calendars[0].month + t, year: this.calendars[0].year }); this.draw() }, gotoToday: function() { this.gotoDate(new Date) }, gotoMonth: function(t) { isNaN(t) || (this.calendars[0].month = parseInt(t, 10), this.adjustCalendars()) }, nextMonth: function() { this.calendars[0].month++, this.adjustCalendars() }, prevMonth: function() { this.calendars[0].month--, this.adjustCalendars() }, gotoYear: function(t) { isNaN(t) || (this.calendars[0].year = parseInt(t, 10), this.adjustCalendars()) }, setMinDate: function(t) { t instanceof Date ? (v(t), this._o.minDate = t, this._o.minYear = t.getFullYear(), this._o.minMonth = t.getMonth()) : (this._o.minDate = z.minDate, this._o.minYear = z.minYear, this._o.minMonth = z.minMonth, this._o.startRange = z.startRange), this.draw() }, setMaxDate: function(t) { t instanceof Date ? (v(t), this._o.maxDate = t, this._o.maxYear = t.getFullYear(), this._o.maxMonth = t.getMonth()) : (this._o.maxDate = z.maxDate, this._o.maxYear = z.maxYear, this._o.maxMonth = z.maxMonth, this._o.endRange = z.endRange), this.draw() }, setStartRange: function(t) { this._o.startRange = t }, setEndRange: function(t) { this._o.endRange = t }, draw: function(t) { if (this._v || t) { var e, o = this._o, i = o.minYear, s = o.maxYear, r = o.minMonth, a = o.maxMonth, l = ""; this._y <= i && (this._y = i, !isNaN(r) && this._m < r && (this._m = r)), this._y >= s && (this._y = s, !isNaN(a) && this._m > a && (this._m = a)), e = "pika-title-" + Math.random().toString(36).replace(/[^a-z]+/g, "").substr(0, 2); for (var h = 0; h < o.numberOfMonths; h++) l += '
    ' + E(this, h, this.calendars[h].year, this.calendars[h].month, this.calendars[0].year, e) + this.render(this.calendars[h].year, this.calendars[h].month, e) + "
    "; this.el.innerHTML = l, o.bound && "hidden" !== o.field.type && n(function() { o.trigger.focus() }, 1), "function" == typeof this._o.onDraw && this._o.onDraw(this), o.bound && o.field.setAttribute("aria-label", "Use the arrow keys to pick a date") } }, adjustPosition: function() { var t, e, o, n, s, r, a, l, h, d; if (!this._o.container) { if (this.el.style.position = "absolute", t = this._o.trigger, e = t, o = this.el.offsetWidth, n = this.el.offsetHeight, s = window.innerWidth || i.documentElement.clientWidth, r = window.innerHeight || i.documentElement.clientHeight, a = window.pageYOffset || i.body.scrollTop || i.documentElement.scrollTop, "function" == typeof t.getBoundingClientRect) d = t.getBoundingClientRect(), l = d.left + window.pageXOffset, h = d.bottom + window.pageYOffset; else for (l = e.offsetLeft, h = e.offsetTop + e.offsetHeight; e = e.offsetParent;) l += e.offsetLeft, h += e.offsetTop; (this._o.reposition && l + o > s || this._o.position.indexOf("right") > -1 && l - o + t.offsetWidth > 0) && (l = l - o + t.offsetWidth), (this._o.reposition && h + n > r + a || this._o.position.indexOf("top") > -1 && h - n - t.offsetHeight > 0) && (h = h - n - t.offsetHeight), this.el.style.left = l + "px", this.el.style.top = h + "px" } }, render: function(t, e, o) { var i = this._o, n = new Date, s = g(t, e), r = new Date(t, e, 1).getDay(), a = [], l = []; v(n), i.firstDay > 0 && (r -= i.firstDay, r < 0 && (r += 7)); for (var h = 0 === e ? 11 : e - 1, d = 11 === e ? 0 : e + 1, c = 0 === e ? t - 1 : t, p = 11 === e ? t + 1 : t, m = g(c, h), w = s + r, b = w; b > 7;) b -= 7; w += 7 - b; for (var z = 0, T = 0; z < w; z++) { var L = new Date(t, e, 1 + (z - r)), S = !!u(this._d) && y(L, this._d), E = y(L, n), O = z < r || z >= s + r, _ = 1 + (z - r), I = e, P = t, $ = i.startRange && y(i.startRange, L), D = i.endRange && y(i.endRange, L), M = i.startRange && i.endRange && i.startRange < L && L < i.endRange, R = i.minDate && L < i.minDate || i.maxDate && L > i.maxDate || i.disableWeekends && f(L) || i.disableDayFn && i.disableDayFn(L); O && (z < r ? (_ = m + _, I = h, P = c) : (_ -= s, I = d, P = p)); var A = { day: _, month: I, year: P, isSelected: S, isToday: E, isDisabled: R, isEmpty: O, isStartRange: $, isEndRange: D, isInRange: M, showDaysInNextAndPreviousMonths: i.showDaysInNextAndPreviousMonths }; l.push(x(A)), 7 === ++T && (i.showWeekNumber && l.unshift(k(z - r, e, t)), a.push(C(l, i.isRTL)), l = [], T = 0) } return W(i, a, o) }, isVisible: function() { return this._v }, show: function() { this.isVisible() || (c(this.el, "is-hidden"), this._v = !0, this.draw(), this._o.bound && (s(i, "click", this._onClick), this.adjustPosition()), "function" == typeof this._o.onOpen && this._o.onOpen.call(this)) }, hide: function() { var t = this._v; t !== !1 && (this._o.bound && r(i, "click", this._onClick), this.el.style.position = "static", this.el.style.left = "auto", this.el.style.top = "auto", d(this.el, "is-hidden"), this._v = !1, void 0 !== t && "function" == typeof this._o.onClose && this._o.onClose.call(this)) }, destroy: function() { this.hide(), r(this.el, "mousedown", this._onMouseDown, !0), r(this.el, "touchend", this._onMouseDown, !0), r(this.el, "change", this._onChange), this._o.field && (r(this._o.field, "change", this._onInputChange), this._o.bound && (r(this._o.trigger, "click", this._onInputClick), r(this._o.trigger, "focus", this._onInputFocus), r(this._o.trigger, "blur", this._onInputBlur))), this.el.parentNode && this.el.parentNode.removeChild(this.el) } }, O }), document.addEventListener("DOMContentLoaded", function() { var t = function() { if ("scrollingElement" in document) return document.scrollingElement; var t = document.documentElement, e = t.scrollTop; t.scrollTop = e + 1; var o = t.scrollTop; return t.scrollTop = e, o > e ? t : document.body }(), e = function(e) { var o = t.scrollTop; if (2 > e.length) e = -o; else if (e = document.querySelector(e)) { e = e.getBoundingClientRect().top; var i = t.scrollHeight - window.innerHeight; e = o + e < i ? e : i - o } else e = void 0; if (e) return new Map([ ["start", o], ["delta", e] ]) }, o = function(o) { var i = o.getAttribute("href"), n = e(i); if (n) { var s = new Map([ ["duration", 800] ]), r = performance.now(); requestAnimationFrame(function e(o) { s.set("elapsed", o - r), o = s.get("duration"); var a = s.get("elapsed"), l = n.get("start"), h = n.get("delta"); t.scrollTop = Math.round(h * (-Math.pow(2, -10 * a / o) + 1) + l), s.get("elapsed") < s.get("duration") ? requestAnimationFrame(e) : (history.pushState(null, null, i), t.scrollTop = n.get("start") + n.get("delta")) }) } }, i = function t(e, i) { var n = e.item(i); if (n.addEventListener("click", function(t) { t.preventDefault(), o(n) }), i) return t(e, i - 1) }, n = document.querySelectorAll("a.scroll"), s = n.length - 1; 0 > s || i(n, s) }), ! function(t, e, o) { "use strict"; function i(o) { if (n = e.documentElement, s = e.body, U(), at = this, o = o || {}, pt = o.constants || {}, o.easing) for (var i in o.easing) V[i] = o.easing[i]; wt = o.edgeStrategy || "set", dt = { beforerender: o.beforerender, render: o.render, keyframe: o.keyframe }, ct = o.forceHeight !== !1, ct && (Mt = o.scale || 1), ut = o.mobileDeceleration || k, mt = o.smoothScrolling !== !1, gt = o.smoothScrollingDuration || L, vt = { targetTop: at.getScrollTop() }, Yt = (o.mobileCheck || function() { return /Android|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent || navigator.vendor || t.opera) })(), Yt ? (ht = e.getElementById(o.skrollrBody || C), ht && rt(), X(), Ot(n, [y, z], [w])) : Ot(n, [y, b], [w]), at.refresh(), Tt(t, "resize orientationchange", function() { var t = n.clientWidth, e = n.clientHeight; (e !== jt || t !== Nt) && (jt = e, Nt = t, Bt = !0) }); var r = q(); return function t() { K(), zt = r(t) }(), at } var n, s, r = { get: function() { return at }, init: function(t) { return at || new i(t) }, VERSION: "0.6.30" }, a = Object.prototype.hasOwnProperty, l = t.Math, h = t.getComputedStyle, d = "touchstart", c = "touchmove", p = "touchcancel", u = "touchend", f = "skrollable", m = f + "-before", g = f + "-between", v = f + "-after", y = "skrollr", w = "no-" + y, b = y + "-desktop", z = y + "-mobile", T = "linear", x = 1e3, k = .004, C = "skrollr-body", L = 200, S = "start", E = "end", W = "center", O = "bottom", _ = "___skrollable_id", I = /^(?:input|textarea|button|select)$/i, P = /^\s+|\s+$/g, $ = /^data(?:-(_\w+))?(?:-?(-?\d*\.?\d+p?))?(?:-?(start|end|top|center|bottom))?(?:-?(top|center|bottom))?$/, D = /\s*(@?[\w\-\[\]]+)\s*:\s*(.+?)\s*(?:;|$)/gi, M = /^(@?[a-z\-]+)\[(\w+)\]$/, R = /-([a-z0-9_])/g, A = function(t, e) { return e.toUpperCase() }, H = /[\-+]?[\d]*\.?[\d]+/g, N = /\{\?\}/g, j = /rgba?\(\s*-?\d+\s*,\s*-?\d+\s*,\s*-?\d+/g, B = /[a-z\-]+-gradient/g, F = "", Y = "", U = function() { var t = /^(?:O|Moz|webkit|ms)|(?:-(?:o|moz|webkit|ms)-)/; if (h) { var e = h(s, null); for (var o in e) if (F = o.match(t) || +o == o && e[o].match(t)) break; if (!F) return void(F = Y = ""); F = F[0], "-" === F.slice(0, 1) ? (Y = F, F = { "-webkit-": "webkit", "-moz-": "Moz", "-ms-": "ms", "-o-": "O" }[F]) : Y = "-" + F.toLowerCase() + "-" } }, q = function() { var e = t.requestAnimationFrame || t[F.toLowerCase() + "RequestAnimationFrame"], o = Pt(); return (Yt || !e) && (e = function(e) { var i = Pt() - o, n = l.max(0, 1e3 / 60 - i); return t.setTimeout(function() { o = Pt(), e() }, n) }), e }, Z = function() { var e = t.cancelAnimationFrame || t[F.toLowerCase() + "CancelAnimationFrame"]; return (Yt || !e) && (e = function(e) { return t.clearTimeout(e) }), e }, V = { begin: function() { return 0 }, end: function() { return 1 }, linear: function(t) { return t }, quadratic: function(t) { return t * t }, cubic: function(t) { return t * t * t }, swing: function(t) { return -l.cos(t * l.PI) / 2 + .5 }, sqrt: function(t) { return l.sqrt(t) }, outCubic: function(t) { return l.pow(t - 1, 3) + 1 }, bounce: function(t) { var e; if (.5083 >= t) e = 3; else if (.8489 >= t) e = 9; else if (.96208 >= t) e = 27; else { if (!(.99981 >= t)) return 1; e = 91 } return 1 - l.abs(3 * l.cos(t * e * 1.028) / e) } }; i.prototype.refresh = function(t) { var i, n, s = !1; for (t === o ? (s = !0, lt = [], Ft = 0, t = e.getElementsByTagName("*")) : t.length === o && (t = [t]), i = 0, n = t.length; n > i; i++) { var r = t[i], a = r, l = [], h = mt, d = wt, c = !1; if (s && _ in r && delete r[_], r.attributes) { for (var p = 0, u = r.attributes.length; u > p; p++) { var m = r.attributes[p]; if ("data-anchor-target" !== m.name) if ("data-smooth-scrolling" !== m.name) if ("data-edge-strategy" !== m.name) if ("data-emit-events" !== m.name) { var g = m.name.match($); if (null !== g) { var v = { props: m.value, element: r, eventType: m.name.replace(R, A) }; l.push(v); var y = g[1]; y && (v.constant = y.substr(1)); var w = g[2]; /p$/.test(w) ? (v.isPercentage = !0, v.offset = (0 | w.slice(0, -1)) / 100) : v.offset = 0 | w; var b = g[3], z = g[4] || b; b && b !== S && b !== E ? (v.mode = "relative", v.anchors = [b, z]) : (v.mode = "absolute", b === E ? v.isEnd = !0 : v.isPercentage || (v.offset = v.offset * Mt)) } } else c = !0; else d = m.value; else h = "off" !== m.value; else if (a = e.querySelector(m.value), null === a) throw 'Unable to find anchor target "' + m.value + '"' } if (l.length) { var T, x, k; !s && _ in r ? (k = r[_], T = lt[k].styleAttr, x = lt[k].classAttr) : (k = r[_] = Ft++, T = r.style.cssText, x = Wt(r)), lt[k] = { element: r, styleAttr: T, classAttr: x, anchorTarget: a, keyFrames: l, smoothScrolling: h, edgeStrategy: d, emitEvents: c, lastFrameIndex: -1 }, Ot(r, [f], []) } } } for (Lt(), i = 0, n = t.length; n > i; i++) { var C = lt[t[i][_]]; C !== o && (J(C), et(C)) } return at }, i.prototype.relativeToAbsolute = function(t, e, o) { var i = n.clientHeight, s = t.getBoundingClientRect(), r = s.top, a = s.bottom - s.top; return e === O ? r -= i : e === W && (r -= i / 2), o === O ? r += a : o === W && (r += a / 2), r += at.getScrollTop(), r + .5 | 0 }, i.prototype.animateTo = function(t, e) { e = e || {}; var i = Pt(), n = at.getScrollTop(), s = e.duration === o ? x : e.duration; return ft = { startTop: n, topDiff: t - n, targetTop: t, duration: s, startTime: i, endTime: i + s, easing: V[e.easing || T], done: e.done }, ft.topDiff || (ft.done && ft.done.call(at, !1), ft = o), at }, i.prototype.stopAnimateTo = function() { ft && ft.done && ft.done.call(at, !0), ft = o }, i.prototype.isAnimatingTo = function() { return !!ft }, i.prototype.isMobile = function() { return Yt }, i.prototype.setScrollTop = function(e, o) { return yt = o === !0, Yt ? Ut = l.min(l.max(e, 0), Dt) : t.scrollTo(0, e), at }, i.prototype.getScrollTop = function() { return Yt ? Ut : t.pageYOffset || n.scrollTop || s.scrollTop || 0 }, i.prototype.getMaxScrollTop = function() { return Dt }, i.prototype.on = function(t, e) { return dt[t] = e, at }, i.prototype.off = function(t) { return delete dt[t], at }, i.prototype.destroy = function() { var t = Z(); t(zt), kt(), Ot(n, [w], [y, b, z]); for (var e = 0, i = lt.length; i > e; e++) st(lt[e].element); n.style.overflow = s.style.overflow = "", n.style.height = s.style.height = "", ht && r.setStyle(ht, "transform", "none"), at = o, ht = o, dt = o, ct = o, Dt = 0, Mt = 1, pt = o, ut = o, Rt = "down", At = -1, Nt = 0, jt = 0, Bt = !1, ft = o, mt = o, gt = o, vt = o, yt = o, Ft = 0, wt = o, Yt = !1, Ut = 0, bt = o }; var X = function() { var i, r, a, h, f, m, g, v, y, w, b, z; Tt(n, [d, c, p, u].join(" "), function(t) { var n = t.changedTouches[0]; for (h = t.target; 3 === h.nodeType;) h = h.parentNode; switch (f = n.clientY, m = n.clientX, w = t.timeStamp, I.test(h.tagName) || t.preventDefault(), t.type) { case d: i && i.blur(), at.stopAnimateTo(), i = h, r = g = f, a = m, y = w; break; case c: I.test(h.tagName) && e.activeElement !== h && t.preventDefault(), v = f - g, z = w - b, at.setScrollTop(Ut - v, !0), g = f, b = w; break; default: case p: case u: var s = r - f, T = a - m, x = T * T + s * s; if (49 > x) { if (!I.test(i.tagName)) { i.focus(); var k = e.createEvent("MouseEvents"); k.initMouseEvent("click", !0, !0, t.view, 1, n.screenX, n.screenY, n.clientX, n.clientY, t.ctrlKey, t.altKey, t.shiftKey, t.metaKey, 0, null), i.dispatchEvent(k) } return } i = o; var C = v / z; C = l.max(l.min(C, 3), -3); var L = l.abs(C / ut), S = C * L + .5 * ut * L * L, E = at.getScrollTop() - S, W = 0; E > Dt ? (W = (Dt - E) / S, E = Dt) : 0 > E && (W = -E / S, E = 0), L *= 1 - W, at.animateTo(E + .5 | 0, { easing: "outCubic", duration: L }) } }), t.scrollTo(0, 0), n.style.overflow = s.style.overflow = "hidden" }, G = function() { var t, e, o, i, s, r, a, h, d, c, p, u = n.clientHeight, f = St(); for (h = 0, d = lt.length; d > h; h++) for (t = lt[h], e = t.element, o = t.anchorTarget, i = t.keyFrames, s = 0, r = i.length; r > s; s++) a = i[s], c = a.offset, p = f[a.constant] || 0, a.frame = c, a.isPercentage && (c *= u, a.frame = c), "relative" === a.mode && (st(e), a.frame = at.relativeToAbsolute(o, a.anchors[0], a.anchors[1]) - c, st(e, !0)), a.frame += p, ct && !a.isEnd && a.frame > Dt && (Dt = a.frame); for (Dt = l.max(Dt, Et()), h = 0, d = lt.length; d > h; h++) { for (t = lt[h], i = t.keyFrames, s = 0, r = i.length; r > s; s++) a = i[s], p = f[a.constant] || 0, a.isEnd && (a.frame = Dt - a.offset + p); t.keyFrames.sort($t) } }, Q = function(t, e) { for (var o = 0, i = lt.length; i > o; o++) { var n, s, l = lt[o], h = l.element, d = l.smoothScrolling ? t : e, c = l.keyFrames, p = c.length, u = c[0], y = c[c.length - 1], w = d < u.frame, b = d > y.frame, z = w ? u : y, T = l.emitEvents, x = l.lastFrameIndex; if (w || b) { if (w && -1 === l.edge || b && 1 === l.edge) continue; switch (w ? (Ot(h, [m], [v, g]), T && x > -1 && (Ct(h, u.eventType, Rt), l.lastFrameIndex = -1)) : (Ot(h, [v], [m, g]), T && p > x && (Ct(h, y.eventType, Rt), l.lastFrameIndex = p)), l.edge = w ? -1 : 1, l.edgeStrategy) { case "reset": st(h); continue; case "ease": d = z.frame; break; default: case "set": var k = z.props; for (n in k) a.call(k, n) && (s = nt(k[n].value), 0 === n.indexOf("@") ? h.setAttribute(n.substr(1), s) : r.setStyle(h, n, s)); continue } } else 0 !== l.edge && (Ot(h, [f, g], [m, v]), l.edge = 0); for (var C = 0; p - 1 > C; C++) if (d >= c[C].frame && d <= c[C + 1].frame) { var L = c[C], S = c[C + 1]; for (n in L.props) if (a.call(L.props, n)) { var E = (d - L.frame) / (S.frame - L.frame); E = L.props[n].easing(E), s = it(L.props[n].value, S.props[n].value, E), s = nt(s), 0 === n.indexOf("@") ? h.setAttribute(n.substr(1), s) : r.setStyle(h, n, s) } T && x !== C && ("down" === Rt ? Ct(h, L.eventType, Rt) : Ct(h, S.eventType, Rt), l.lastFrameIndex = C); break } } }, K = function() { Bt && (Bt = !1, Lt()); var t, e, i = at.getScrollTop(), n = Pt(); if (ft) n >= ft.endTime ? (i = ft.targetTop, t = ft.done, ft = o) : (e = ft.easing((n - ft.startTime) / ft.duration), i = ft.startTop + e * ft.topDiff | 0), at.setScrollTop(i, !0); else if (!yt) { var s = vt.targetTop - i; s && (vt = { startTop: At, topDiff: i - At, targetTop: i, startTime: Ht, endTime: Ht + gt }), n <= vt.endTime && (e = V.sqrt((n - vt.startTime) / gt), i = vt.startTop + e * vt.topDiff | 0) } if (yt || At !== i) { Rt = i > At ? "down" : At > i ? "up" : Rt, yt = !1; var a = { curTop: i, lastTop: At, maxTop: Dt, direction: Rt }, l = dt.beforerender && dt.beforerender.call(at, a); l !== !1 && (Q(i, at.getScrollTop()), Yt && ht && r.setStyle(ht, "transform", "translate(0, " + -Ut + "px) " + bt), At = i, dt.render && dt.render.call(at, a)), t && t.call(at, !1) } Ht = n }, J = function(t) { for (var e = 0, o = t.keyFrames.length; o > e; e++) { for (var i, n, s, r, a = t.keyFrames[e], l = {}; null !== (r = D.exec(a.props));) s = r[1], n = r[2], i = s.match(M), null !== i ? (s = i[1], i = i[2]) : i = T, n = n.indexOf("!") ? tt(n) : [n.slice(1)], l[s] = { value: n, easing: V[i] }; a.props = l } }, tt = function(t) { var e = []; return j.lastIndex = 0, t = t.replace(j, function(t) { return t.replace(H, function(t) { return t / 255 * 100 + "%" }) }), Y && (B.lastIndex = 0, t = t.replace(B, function(t) { return Y + t })), t = t.replace(H, function(t) { return e.push(+t), "{?}" }), e.unshift(t), e }, et = function(t) { var e, o, i = {}; for (e = 0, o = t.keyFrames.length; o > e; e++) ot(t.keyFrames[e], i); for (i = {}, e = t.keyFrames.length - 1; e >= 0; e--) ot(t.keyFrames[e], i) }, ot = function(t, e) { var o; for (o in e) a.call(t.props, o) || (t.props[o] = e[o]); for (o in t.props) e[o] = t.props[o] }, it = function(t, e, o) { var i, n = t.length; if (n !== e.length) throw "Can't interpolate between \"" + t[0] + '" and "' + e[0] + '"'; var s = [t[0]]; for (i = 1; n > i; i++) s[i] = t[i] + (e[i] - t[i]) * o; return s }, nt = function(t) { var e = 1; return N.lastIndex = 0, t[0].replace(N, function() { return t[e++] }) }, st = function(t, e) { t = [].concat(t); for (var o, i, n = 0, s = t.length; s > n; n++) i = t[n], o = lt[i[_]], o && (e ? (i.style.cssText = o.dirtyStyleAttr, Ot(i, o.dirtyClassAttr)) : (o.dirtyStyleAttr = i.style.cssText, o.dirtyClassAttr = Wt(i), i.style.cssText = o.styleAttr, Ot(i, o.classAttr))) }, rt = function() { bt = "translateZ(0)", r.setStyle(ht, "transform", bt); var t = h(ht), e = t.getPropertyValue("transform"), o = t.getPropertyValue(Y + "transform"), i = e && "none" !== e || o && "none" !== o; i || (bt = "") }; r.setStyle = function(t, e, o) { var i = t.style; if (e = e.replace(R, A).replace("-", ""), "zIndex" === e) isNaN(o) ? i[e] = o : i[e] = "" + (0 | o); else if ("float" === e) i.styleFloat = i.cssFloat = o; else try { F && (i[F + e.slice(0, 1).toUpperCase() + e.slice(1)] = o), i[e] = o } catch (t) {} }; var at, lt, ht, dt, ct, pt, ut, ft, mt, gt, vt, yt, wt, bt, zt, Tt = r.addEvent = function(e, o, i) { var n = function(e) { return e = e || t.event, e.target || (e.target = e.srcElement), e.preventDefault || (e.preventDefault = function() { e.returnValue = !1, e.defaultPrevented = !0 }), i.call(this, e) }; o = o.split(" "); for (var s, r = 0, a = o.length; a > r; r++) s = o[r], e.addEventListener ? e.addEventListener(s, i, !1) : e.attachEvent("on" + s, n), qt.push({ element: e, name: s, listener: i }) }, xt = r.removeEvent = function(t, e, o) { e = e.split(" "); for (var i = 0, n = e.length; n > i; i++) t.removeEventListener ? t.removeEventListener(e[i], o, !1) : t.detachEvent("on" + e[i], o) }, kt = function() { for (var t, e = 0, o = qt.length; o > e; e++) t = qt[e], xt(t.element, t.name, t.listener); qt = [] }, Ct = function(t, e, o) { dt.keyframe && dt.keyframe.call(at, t, e, o) }, Lt = function() { var t = at.getScrollTop(); Dt = 0, ct && !Yt && (s.style.height = ""), G(), ct && !Yt && (s.style.height = Dt + n.clientHeight + "px"), Yt ? at.setScrollTop(l.min(at.getScrollTop(), Dt)) : at.setScrollTop(t, !0), yt = !0 }, St = function() { var t, e, o = n.clientHeight, i = {}; for (t in pt) e = pt[t], "function" == typeof e ? e = e.call(at) : /p$/.test(e) && (e = e.slice(0, -1) / 100 * o), i[t] = e; return i }, Et = function() { var t, e = 0; return ht && (e = l.max(ht.offsetHeight, ht.scrollHeight)), t = l.max(e, s.scrollHeight, s.offsetHeight, n.scrollHeight, n.offsetHeight, n.clientHeight), t - n.clientHeight }, Wt = function(e) { var o = "className"; return t.SVGElement && e instanceof t.SVGElement && (e = e[o], o = "baseVal"), e[o] }, Ot = function(e, i, n) { var s = "className"; if (t.SVGElement && e instanceof t.SVGElement && (e = e[s], s = "baseVal"), n === o) return void(e[s] = i); for (var r = e[s], a = 0, l = n.length; l > a; a++) r = It(r).replace(It(n[a]), " "); r = _t(r); for (var h = 0, d = i.length; d > h; h++) - 1 === It(r).indexOf(It(i[h])) && (r += " " + i[h]); e[s] = _t(r) }, _t = function(t) { return t.replace(P, "") }, It = function(t) { return " " + t + " " }, Pt = Date.now || function() { return +new Date }, $t = function(t, e) { return t.frame - e.frame }, Dt = 0, Mt = 1, Rt = "down", At = -1, Ht = Pt(), Nt = 0, jt = 0, Bt = !1, Ft = 0, Yt = !1, Ut = 0, qt = []; "function" == typeof define && define.amd ? define([], function() { return r }) : "undefined" != typeof module && module.exports ? module.exports = r : t.skrollr = r }(window, document), "function" != typeof Object.create && (Object.create = function(t) { function e() {} return e.prototype = t, new e }), function(t, e, o) { var i = function(t) { var i = o.createElement("script"), s = o.getElementsByTagName("head")[0]; "file://" == e.location.origin ? i.src = "http://www.youtube.com/iframe_api" : i.src = "//www.youtube.com/iframe_api", s.appendChild(i), s = null, i = null, n(t) }, n = function(o) { "undefined" == typeof YT && "undefined" == typeof e.loadingPlayer ? (e.loadingPlayer = !0, e.dfd = t.Deferred(), e.onYouTubeIframeAPIReady = function() { e.onYouTubeIframeAPIReady = null, e.dfd.resolve("done"), o() }) : "object" == typeof YT ? o() : e.dfd.done(function(t) { o() }) }; YTPlayer = { player: null, defaults: { ratio: 16 / 9, videoId: "LSmgKRx5pBo", mute: !0, repeat: !0, width: t(e).width(), playButtonClass: "YTPlayer-play", pauseButtonClass: "YTPlayer-pause", muteButtonClass: "YTPlayer-mute", volumeUpClass: "YTPlayer-volume-up", volumeDownClass: "YTPlayer-volume-down", start: 0, pauseOnScroll: !1, fitToBackground: !0, playerVars: { iv_load_policy: 3, modestbranding: 1, autoplay: 1, controls: 0, showinfo: 0, wmode: "opaque", branding: 0, autohide: 0 }, events: null }, init: function(o, n) { var s = this; return s.userOptions = n, s.$body = t("body"), s.$node = t(o), s.$window = t(e), s.defaults.events = { onReady: function(t) { s.onPlayerReady(t), s.options.pauseOnScroll && s.pauseOnScroll(), "function" == typeof s.options.callback && s.options.callback.call(this) }, onStateChange: function(t) { 1 === t.data ? (s.$node.find("img").fadeOut(400), s.$node.addClass("loaded")) : 0 === t.data && s.options.repeat && s.player.seekTo(s.options.start) } }, s.options = t.extend(!0, {}, s.defaults, s.userOptions), s.options.height = Math.ceil(s.options.width / s.options.ratio), s.ID = (new Date).getTime(), s.holderID = "YTPlayer-ID-" + s.ID, s.options.fitToBackground ? s.createBackgroundVideo() : s.createContainerVideo(), s.$window.on("resize.YTplayer" + s.ID, function() { s.resize(s) }), i(s.onYouTubeIframeAPIReady.bind(s)), s.resize(s), s }, pauseOnScroll: function() { var t = this; t.$window.on("scroll.YTplayer" + t.ID, function() { var e = t.player.getPlayerState(); 1 === e && t.player.pauseVideo() }), t.$window.scrollStopped(function() { var e = t.player.getPlayerState(); 2 === e && t.player.playVideo() }) }, createContainerVideo: function() { var e = this, o = t('
    '); e.$node.append(o), e.$YTPlayerString = o, o = null }, createBackgroundVideo: function() { var e = this, o = t('
    '); e.$node.append(o), e.$YTPlayerString = o, o = null }, resize: function(o) { var i = t(e); o.options.fitToBackground || (i = o.$node); var n, s, r = i.width(), a = i.height(), l = t("#" + o.holderID); r / o.options.ratio < a ? (n = Math.ceil(a * o.options.ratio), l.width(n).height(a).css({ left: (r - n) / 2, top: 0 })) : (s = Math.ceil(r / o.options.ratio), l.width(r).height(s).css({ left: 0, top: (a - s) / 2 })), l = null, i = null }, onYouTubeIframeAPIReady: function() { var t = this; t.player = new e.YT.Player(t.holderID, t.options) }, onPlayerReady: function(t) { this.options.mute && t.target.mute(), t.target.playVideo() }, getPlayer: function() { return this.player }, destroy: function() { var o = this; o.$node.removeData("yt-init").removeData("ytPlayer").removeClass("loaded"), o.$YTPlayerString.remove(), t(e).off("resize.YTplayer" + o.ID), t(e).off("scroll.YTplayer" + o.ID), o.$body = null, o.$node = null, o.$YTPlayerString = null, o.player.destroy(), o.player = null } }, t.fn.scrollStopped = function(e) { var o = t(this), i = this; o.scroll(function() { o.data("scrollTimeout") && clearTimeout(o.data("scrollTimeout")), o.data("scrollTimeout", setTimeout(e, 250, i)) }) }, t.fn.YTPlayer = function(e) { return this.each(function() { var o = this; t(o).data("yt-init", !0); var i = Object.create(YTPlayer); i.init(o, e), t.data(o, "ytPlayer", i) }) } }(jQuery, window, document), function() { function t(t, e, i) { o(e); var n = t.style, s = {}; for (var r in e) i && (s[r] = n[r] || ""), n[r] = e[r]; return s } function e() { var t = {}, e = ["webkitTransition", "transition", "mozTransition"], o = ["webkitTransform", "transform", "mozTransform"], i = { transition: "transitionend", mozTransition: "transitionend", webkitTransition: "webkitTransitionEnd" }; return e.some(function(e) { if (void 0 !== d.style[e]) return t.transition = e, t.transEnd = i[e], !0 }), o.some(function(e) { if (void 0 !== d.style[e]) return t.transform = e, !0 }), t } function o(t) { var e; t.transition && (e = t.transition, delete t.transition, t[g] = e), t.transform && (e = t.transform, delete t.transform, t[v] = e) } function i(e, o) { for (var i, n = getComputedStyle(e), s = document.createElement("div"), r = b.length; r--;) i = b[r], s.style[i] = n[i]; return t(s, { visibility: "hidden", width: o.width + "px", height: o.height + "px", display: "inline" === n.display ? "inline-block" : n.display }), f.deepCopy ? s.innerHTML = e.innerHTML : s.textContent = e.textContent, s } var n, s, r, a, l = "WebkitAppearance" in document.documentElement.style ? "-webkit-" : "", h = /^([\d\.]+)%$/, d = document.createElement("div"), c = document.createElement("div"), p = !1, u = !1, f = { transitionDuration: ".4s", transitionTimingFunction: "cubic-bezier(.4,0,0,1)", bgColor: "#fff", bgOpacity: 1, maxWidth: 300, maxHeight: 300, onOpen: null, onClose: null, onBeforeClose: null, onBeforeOpen: null }, m = e(), g = m.transition, v = m.transform, y = v.replace(/(.*)Transform/, "-$1-transform"), w = m.transEnd; t(d, { position: "fixed", display: "none", zIndex: 99998, top: 0, left: 0, right: 0, bottom: 0, opacity: 0, backgroundColor: f.bgColor, cursor: l + "zoom-out", transition: "opacity " + f.transitionDuration + " " + f.transitionTimingFunction }), t(c, { position: "fixed", zIndex: 99999, top: "50%", left: "50%", width: 0, height: 0 }); var b = ["position", "display", "float", "top", "left", "right", "bottom", "marginBottom", "marginLeft", "marginRight", "marginTop", "font", "lineHeight", "verticalAlign"], z = { config: function(e) { if (!e) return f; for (var o in e) f[o] = e[o]; return t(d, { backgroundColor: f.bgColor, transition: "opacity " + f.transitionDuration + " " + f.transitionTimingFunction }), this }, open: function(e, o) { if (!p && !u) { n = "string" == typeof e ? document.querySelector(e) : e, f.onBeforeOpen && f.onBeforeOpen(n), p = !0, u = !0, s = n.parentNode; var m = n.getBoundingClientRect(), g = Math.min(f.maxWidth / m.width, f.maxHeight / m.height), v = m.left - (window.innerWidth - m.width) / 2, b = m.top - (window.innerHeight - m.height) / 2; r = i(n, m), a = t(n, { position: "absolute", top: 0, left: 0, right: "", bottom: "", whiteSpace: "nowrap", marginTop: -m.height / 2 + "px", marginLeft: -m.width / 2 + "px", cursor: l + "zoom-out", transform: "translate(" + v + "px, " + b + "px)", transition: "" }, !0); var z = n.style.width.match(h), T = n.style.height.match(h); if (z || T) { var x = z ? +z[1] / 100 : 1, k = T ? +T[1] / 100 : 1; t(c, { width: ~~(m.width / x) + "px", height: ~~(m.height / k) + "px" }) } s.appendChild(d), s.appendChild(c), s.insertBefore(r, n), c.appendChild(n), d.style.display = "block"; n.offsetHeight; return d.style.opacity = f.bgOpacity, t(n, { transition: y + " " + f.transitionDuration + " " + f.transitionTimingFunction, transform: "scale(" + g + ")" }), n.addEventListener(w, function t() { n.removeEventListener(w, t), u = !1, o = o || f.onOpen, o && o(n) }), this } }, close: function(e) { if (p && !u) { u = !0, f.onBeforeClose && f.onBeforeClose(n); var o = r.getBoundingClientRect(), i = o.left - (window.innerWidth - o.width) / 2, l = o.top - (window.innerHeight - o.height) / 2; return d.style.opacity = 0, t(n, { transform: "translate(" + i + "px, " + l + "px)" }), n.addEventListener(w, function o() { n.removeEventListener(w, o), t(n, a), s.insertBefore(n, r), s.removeChild(r), s.removeChild(d), s.removeChild(c), d.style.display = "none", r = null, p = !1, u = !1, e = "function" == typeof e ? e : f.onClose, e && e(n) }), this } }, listen: function e(o) { if ("string" != typeof o) return t(o, { cursor: l + "zoom-in" }), o.addEventListener("click", function(t) { t.stopPropagation(), p ? z.close() : z.open(o) }), this; for (var i = document.querySelectorAll(o), n = i.length; n--;) e(i[n]) } }; d.addEventListener("click", z.close), c.addEventListener("click", z.close), "object" == typeof exports ? module.exports = z : "function" == typeof define && define.amd ? define(function() { return z }) : this.Zoomerang = z }(), $(function() { $("#spacial-slider").length && slider.initialize() }); var slider = { initialize: function() { function t() { h.addEventListener("click", function(t) { t.preventDefault(), navigate_slider("next"), clearInterval(window.slider_interval) }), d.addEventListener("click", function(t) { t.preventDefault(), navigate_slider("prev"), clearInterval(window.slider_interval) }) } var e = { animations: Modernizr.cssanimations }, o = { WebkitAnimation: "webkitAnimationEnd", OAnimation: "oAnimationEnd", msAnimation: "MSAnimationEnd", animation: "animationend" }, i = o[Modernizr.prefixed("animation")], n = document.getElementById("spacial-slider"), s = n.querySelector("ul.itemwrap").children, r = 0, a = s.length, l = n.querySelector("nav"), h = l.querySelector(".next"), d = l.querySelector(".prev"), c = !1; window.navigate_slider = function(t) { if (c) return !1; c = !0; var o = 0, n = s[r]; "next" === t ? r = r < a - 1 ? r + 1 : 0 : "prev" === t && (r = r > 0 ? r - 1 : a - 1); var l = s[r], h = function() { this.removeEventListener(i, h), $(this).removeClass("current"), $(this).removeClass("next" === t ? "navOutNext" : "navOutPrev"), ++o, 2 === o && (c = !1) }, d = function() { this.removeEventListener(i, d), $(this).addClass("current"), $(this).removeClass("next" === t ? "navInNext" : "navInPrev"), ++o, 2 === o && (c = !1) }; e.animations ? (n.addEventListener(i, h), l.addEventListener(i, d)) : (h(), d()), $(n).addClass("next" === t ? "navOutNext" : "navOutPrev"), $(l).addClass("next" === t ? "navInNext" : "navInPrev") }, t() } }; /** 홈페이지 기본 정의 **/ $(function() { navbar.initialize(), settings.initialize(), pricing_charts.initialize(), global_notifications.initialize(), ecommerce.initialize(), retina.initialize(), zoomerang.initialize() }); var settings = { initialize: function() { var t = $("#settings-module"), e = $("#open-settings", t), o = $("[data-option='navbar']", t), i = $("nav.navbar"), n = $("body, html"); e.click(function(e) { e.preventDefault(), t.toggleClass("opened") }), o.click(function(t) { t.preventDefault(); var e = $(this).data("class"); i.removeClass("navbar-default navbar-transparent navbar-inverse").addClass(e), "navbar-default" === e ? i.find(".navbar-brand img").attr("src", "image/logo-alt-b.png") : i.find(".navbar-brand img").attr("src", "image/logo-alt-w.png") }), n.click(function() { t.removeClass("opened") }), t.click(function(t) { t.stopPropagation() }), t.length && ((new Image).src = "image/logo-alt-w.png", (new Image).src = "image/logo-alt-b.png") } }, zoomerang = { initialize: function() { Zoomerang.config({ maxHeight: 730, maxWidth: 900 }).listen('[data-trigger="zoomerang"]') } }, ecommerce = { initialize: function() { this.displayCart(), this.search() }, displayCart: function() { var t, e = $(".store-navbar .cart"), o = $("#cart-modal"), i = function() { o.addClass("visible"), clearTimeout(t), t = null }, n = function() { t = setTimeout(function() { o.removeClass("visible") }, 400) }; e.hover(i, n), o.hover(i, n) }, search: function() { var t = $(".store-navbar .search-field"), e = t.find(".input-search"); e.focus(function() { t.addClass("focus") }), e.blur(function() { t.removeClass("focus") }) } }, navbar = { initialize: function() { this.themeSites(), window.utils.isMobile() || this.dropdowns() }, dropdowns: function() { var t = $(".navbar-nav li.dropdown"); t.each(function(t, e) { var o = $(this); o.hover(function() { o.addClass("open") }, function() { o.removeClass("open") }) }) }, themeSites: function() { var t = $("[data-toggle-header-sections-menu]"), e = $("#header-sections-menu"), o = $("body"); t.click(function(i) { if (i.preventDefault(), o.toggleClass("header-panel-visible"), o.hasClass("header-panel-visible")) { t.find("i").removeClass("ion-plus").addClass("ion-minus"); var n = t.closest(".navbar"); if (n.hasClass("navbar-transparent")) return void e.removeClass("fixed"); n.hasClass("navbar-fixed-top") && e.addClass("fixed") } else t.find("i").removeClass("ion-minus").addClass("ion-plus") }) } }, global_notifications = { initialize: function() { setTimeout(function() { $(".global-notification").removeClass("uber-notification").addClass("uber-notification-remove") }, 5e3) } }, pricing_charts = { initialize: function() { var t = $(".pricing-charts-tabs .tab"), e = $(".pricing-charts .chart header .price"); t.click(function() { t.removeClass("active"), $(this).addClass("active"); var o = $(this).data("tab"), i = e.filter(":not(." + o + ")"); i.addClass("go-out"), e.filter("." + o).addClass("active"), setTimeout(function() { i.removeClass("go-out").removeClass("active") }, 250) }) } }, retina = { initialize: function() { window.devicePixelRatio >= 1.2 && $("[data-2x]").each(function() { "IMG" == this.tagName ? $(this).attr("src", $(this).attr("data-2x")) : $(this).css({ "background-image": "url(" + $(this).attr("data-2x") + ")" }) }) } }; window.utils = { /* load_product_detail: function(classify) { if(classify=='product_ceil_dryer'){ $(".collection-products").load("product_detail_load.html"); } }, */ isFirefox: function() { return navigator.userAgent.toLowerCase().indexOf("firefox") > -1 }, debounce: function(t, e, o) { var i; return function() { var n = this, s = arguments, r = function() { i = null, o || t.apply(n, s) }, a = o && !i; clearTimeout(i), i = setTimeout(r, e), a && t.apply(n, s) } }, isMobile: function() { return window.innerWidth <= 1024 }, parallax_text: function(t, e) { e = "undefined" != typeof e ? e : 0, $(window).scroll(function() { var o, i = $(window).scrollTop(), n = i / 1.4, s = e + n + "px"; "transform" in document.body.style ? "transform" : "-webkit-transform"; o = i > 0 ? (1e3 - 2.7 * i) / 1e3 : 1, t.css({ position: "relative", top: s, opacity: o }) }) } }; //# sourceMappingURL=theme.min.js.map